86 |
|
messagesPane.setBorder(new TitledBorder(new LineBorder(new Color(0, 0, 102)), " Messages ")); |
87 |
|
|
88 |
|
bottom.add(messagesPane, "Center"); |
89 |
< |
bottom.add(_status, "South"); |
89 |
> |
JPanel statusPanel = new JPanel(); |
90 |
> |
statusPanel.setLayout(new GridLayout(1,3)); |
91 |
> |
statusPanel.add(_status); |
92 |
> |
statusPanel.add(_dataLinkStatus); |
93 |
> |
statusPanel.add(_queueStatus); |
94 |
> |
|
95 |
> |
bottom.add(statusPanel, "South"); |
96 |
|
getContentPane().add(bottom, "South"); |
97 |
|
|
98 |
|
// show the window |
110 |
|
_status.repaint(); |
111 |
|
} |
112 |
|
|
113 |
+ |
public static void setQueueStatus(int currentQueue, int numElements) { |
114 |
+ |
_queueStatus.setText("Data Queue : " + currentQueue + " Packets Recieved : " + numElements); |
115 |
+ |
_queueStatus.repaint(); |
116 |
+ |
} |
117 |
+ |
|
118 |
|
public static void addMessage(String message) { |
119 |
|
_messages.insert(message + "\n", 0); |
120 |
|
} |
123 |
|
static JLabel _status = new JLabel("Initialising", JLabel.LEFT); |
124 |
|
{ |
125 |
|
_status.setBorder(new EtchedBorder(EtchedBorder.LOWERED)); |
126 |
< |
} |
126 |
> |
} |
127 |
> |
|
128 |
> |
static JLabel _dataLinkStatus = new JLabel("Data Link Status here soon", JLabel.LEFT); |
129 |
> |
{ |
130 |
> |
_dataLinkStatus.setBorder(new EtchedBorder(EtchedBorder.LOWERED)); |
131 |
> |
} |
132 |
> |
|
133 |
> |
static JLabel _queueStatus = new JLabel("-", JLabel.LEFT); |
134 |
> |
{ |
135 |
> |
_queueStatus.setBorder(new EtchedBorder(EtchedBorder.LOWERED)); |
136 |
> |
} |
137 |
|
|
138 |
|
ImageIcon _serverIcon = new ImageIcon("server.gif"); |
139 |
|
JLabel _serverCountLabel; |