Explorar o código

Small Changes GUI

Edgardo Palza %!s(int64=8) %!d(string=hai) anos
pai
achega
583d6c7486
Modificáronse 7 ficheiros con 6 adicións e 2 borrados
  1. BIN=BIN
      bin/ui/view/GUI$2.class
  2. BIN=BIN
      bin/ui/view/GUI$3.class
  3. BIN=BIN
      bin/ui/view/GUI$4.class
  4. BIN=BIN
      bin/ui/view/GUI$5.class
  5. BIN=BIN
      bin/ui/view/GUI$6.class
  6. BIN=BIN
      bin/ui/view/GUI.class
  7. 6 2
      src/ui/view/GUI.java

BIN=BIN
bin/ui/view/GUI$2.class


BIN=BIN
bin/ui/view/GUI$3.class


BIN=BIN
bin/ui/view/GUI$4.class


BIN=BIN
bin/ui/view/GUI$5.class


BIN=BIN
bin/ui/view/GUI$6.class


BIN=BIN
bin/ui/view/GUI.class


+ 6 - 2
src/ui/view/GUI.java

@@ -145,9 +145,9 @@ public class GUI implements CategoryListener {
 		menuBar.add(mnHelp);
 
 		// Table
-		String[] columnNames = { "Gadget", "Consumption", "Quantity" };
+		String[] columnNames = { "Gadget", "+/-", "Energy", "Quantity" };
 
-		Object[][] data = { { "TV", "20", "1" }, { "PC", "30", "2" }, { "Fridge", "40", "1" } };
+		Object[][] data = {};
 
 		splitPane.setRightComponent(splitPane_1);
 		splitPane.setDividerLocation(200);
@@ -258,6 +258,10 @@ public class GUI implements CategoryListener {
 						for (int i = 0; i < model.getObjectsOnCanvas().size(); i++) {
 							CpsObject temp = model.getObjectsOnCanvas().get(i);
 							String output = "Element: " + temp.getObjName() + " with ID: " + temp.getID();
+
+							if (temp.getClass() == HolonObject.class) {
+								output = output + " and Elements: " + ((HolonObject) temp).toStringElements();
+							}
 							System.out.println(output);
 						}
 						canvas.repaint();