01: /*
02: * AboutFrame.java
03: *
04: * Created on April 16, 2002, 10:47 AM
05: */
06:
07: package tools.tracesviewer;
08:
09: import javax.swing.*;
10: import java.awt.*;
11: import java.awt.event.*;
12:
13: /**
14: *@version 1.2
15: *
16: *
17: *@author Olivier Deruelle <br/>
18: *
19: *
20: *
21: */
22: public class AboutFrame extends JFrame {
23:
24: public TracesAnimationThread animationThread;
25:
26: /** Creates new AboutFrame */
27: public AboutFrame() {
28: super ("About the NIST SIP traces viewer");
29: initComponents();
30: }
31:
32: public void initComponents() {
33: // width, height
34: this .setSize(700, 450);
35: Container container = this .getContentPane();
36: container.setLayout(new BoxLayout(container, BoxLayout.Y_AXIS));
37: container.setBackground(Color.black);
38: this .setResizable(false);
39: this .addWindowListener(new WindowAdapter() {
40: public void windowClosing(WindowEvent e) {
41: animationThread.stop();
42: hide();
43: }
44: });
45:
46: TracesSession tS = new TracesSession();
47:
48: TracesMessage tM1 = new TracesMessage();
49: tM1.setFrom("NIST");
50: tM1.setTo("SIP");
51: tM1.setFirstLine("Ranganathan MUDUMBAI");
52: tM1.setTime("SIP project leader");
53: tM1.setTransactionId("About1");
54: tM1.setStatusInfo("Our boss!!!");
55: tS.addElement(tM1);
56:
57: TracesMessage tM2 = new TracesMessage();
58: tM2.setFrom("SIP");
59: tM2.setTo("TRACESVIEWER");
60: tM2.setFirstLine("Marc BEDNAREK");
61: tM2.setStatusInfo("A french coder!!!");
62: tM2.setTime("Coder");
63: tM2.setTransactionId("About2");
64: tS.addElement(tM2);
65:
66: TracesMessage tM3 = new TracesMessage();
67: tM3.setFrom("TRACESVIEWER");
68: tM3.setTo("SIP");
69: tM3.setFirstLine("Olivier DERUELLE");
70: tM3.setStatusInfo("Myself: french coder !!!");
71: tM3.setTime("Coder");
72: tM3.setTransactionId("About3");
73: tS.addElement(tM3);
74:
75: TracesMessage tM4 = new TracesMessage();
76: tM4.setFrom("SIP");
77: tM4.setTo("NIST");
78: tM4.setFirstLine("Christophe CHAZEAU");
79: tM4
80: .setStatusInfo("Still a french coder: what a french team!!!");
81: tM4.setTime("Coder");
82: tM4.setTransactionId("About4");
83: tS.addElement(tM4);
84:
85: TracesCanvas tracesCanvas = new TracesCanvas(tS,
86: TracesViewer.facesImage, "the NIST-SIP team", 250, null);
87: container.add(tracesCanvas);
88:
89: // Initialisation of the Thread for the animations:
90: animationThread = new TracesAnimationThread(tracesCanvas);
91:
92: }
93:
94: }
|