47 |
|
_name = name; |
48 |
|
_statusAttribute = statusAttribute; |
49 |
|
_attribute = attribute; |
50 |
< |
setLayout(new GridLayout(1,1)); |
50 |
> |
setLayout(new GridLayout(1,2)); |
51 |
> |
_label = new JLabel(_name + ": "); |
52 |
> |
_label.setHorizontalAlignment(JLabel.RIGHT); |
53 |
|
_item = new JTextField("", DEFAULT_TEXT_LENGTH); |
54 |
|
_item.setHorizontalAlignment(JTextField.LEFT); |
55 |
|
_item.setEditable(false); |
56 |
|
_item.setText("-uninitialised-"); |
57 |
+ |
add(_label); |
58 |
|
add(_item); |
59 |
|
setVisible(false); |
60 |
|
} |
73 |
|
} |
74 |
|
if (_statusCache.equals("0")) { |
75 |
|
_item.setForeground(Color.black); |
76 |
< |
_item.setText(_name + "[OK] : " + _cache); |
76 |
> |
_item.setText("[OK] : " + _cache); |
77 |
|
} else { |
78 |
|
_item.setForeground(Color.red); |
79 |
< |
_item.setText(_name + "[FAILED] : " + _cache); |
79 |
> |
_item.setText("[FAILED] : " + _cache); |
80 |
|
} |
81 |
|
_item.setCaretPosition(0); |
82 |
|
} |