Closedown
This commit is contained in:
@@ -174,7 +174,10 @@ public class TestingList extends Panel {
|
||||
}
|
||||
|
||||
public ImageIcon Icon(){
|
||||
ImageIcon icon = new ImageIcon(getClass().getResource(this.IconFilename()));
|
||||
String iconFileName = this.IconFilename();
|
||||
ImageIcon icon = null;
|
||||
if (iconFileName != "")
|
||||
icon = new ImageIcon(getClass().getResource(this.IconFilename()));
|
||||
return icon;
|
||||
}
|
||||
|
||||
@@ -436,22 +439,22 @@ public class TestingList extends Panel {
|
||||
break;
|
||||
}
|
||||
}
|
||||
String iconSource = "/icons/button_help-16px.png";
|
||||
ImageIcon icon = new ImageIcon();
|
||||
switch (status) {
|
||||
case "Success":
|
||||
iconSource = TestStatus.SUCCESS.IconFilename();// "/icons/button_ok-16px.png";
|
||||
icon = TestStatus.SUCCESS.Icon();
|
||||
logger.log(Level.INFO, "Device: " + testName + "; Test: " + testName + " Result: " + res + " (" + status + ")");
|
||||
break;
|
||||
case "Failure":
|
||||
iconSource = TestStatus.FAILURE.IconFilename();//"/icons/button_close-16px.png";
|
||||
icon = TestStatus.FAILURE.Icon();
|
||||
logger.log(Level.SEVERE, "Device: " + testName + "; Test: " + testName + " Result: " + res + " (" + status + ")");
|
||||
break;
|
||||
case "Running":
|
||||
iconSource = "/icons/button_play-16px.png";
|
||||
icon = TestStatus.RUNNING.Icon();
|
||||
logger.log(Level.INFO, "Running Test: " + testName + ".");
|
||||
break;
|
||||
}
|
||||
ImageIcon icon = new ImageIcon(getClass().getResource(iconSource));
|
||||
|
||||
jTable1.setValueAt(icon, rowD, COL.ICON.index());
|
||||
|
||||
if (rowD >= 0) {
|
||||
@@ -516,11 +519,10 @@ public class TestingList extends Panel {
|
||||
bSelected = (boolean) jTable1.getValueAt(row, COL.CHECK.index());
|
||||
if (bSelected) {
|
||||
sStatus = "Pending";
|
||||
String iconSource = "/icons/button_stop-16px.png";
|
||||
icon = new ImageIcon(getClass().getResource(iconSource));
|
||||
icon = TestStatus.PENDING.Icon();
|
||||
} else {
|
||||
sStatus = "Disabled";
|
||||
icon = null;
|
||||
icon = TestStatus.DISABLED.Icon();
|
||||
}
|
||||
jTable1.setValueAt(bSelected, row, COL.CHECK.index());
|
||||
jTable1.setValueAt(icon, row, COL.ICON.index());
|
||||
|
||||
Reference in New Issue
Block a user