Closedown

This commit is contained in:
boccioli_m
2015-06-08 16:38:06 +02:00
parent c7b5dc53b6
commit b85ad07835
2 changed files with 15 additions and 2 deletions

View File

@@ -221,8 +221,21 @@ public class TestingList extends Panel {
private void jCheckBox1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jCheckBox1ActionPerformed
//search for device name in table
for (int row = 0; row <= jTable1.getRowCount() - 1; row++) {
jTable1.setValueAt(this.jCheckBox1.isSelected(), row, 0);
boolean bSelected = jCheckBox1.isSelected();
String sStatus, iconSource;
if(bSelected){
sStatus = "Pending";
iconSource = "/icons/button_pause-16px.png";
}
else{
sStatus = "Disabled";
iconSource = "/icons/button_stop-16px.png";
}
ImageIcon icon = new ImageIcon(getClass().getResource(iconSource));
for (int row = 0; row <= jTable1.getRowCount() - 1; row++) {
jTable1.setValueAt(bSelected, row, 0);
jTable1.setValueAt(icon, row, 6);
jTable1.setValueAt(sStatus, row, 5);
}
}//GEN-LAST:event_jCheckBox1ActionPerformed