|
@@ -183,7 +183,7 @@ public class MyCanvas extends JPanel implements MouseListener, MouseMotionListen
|
|
|
if (((HolonObject) cps).getSupplied()) {
|
|
|
g2.setColor(Color.GREEN);
|
|
|
} else {
|
|
|
- g2.setColor(Color.YELLOW);
|
|
|
+ g2.setColor(Color.ORANGE);
|
|
|
}
|
|
|
g2.fillRect(cps.getPosition().x - (controller.getScale() / 20),
|
|
|
cps.getPosition().y - (controller.getScale() / 20),
|
|
@@ -283,7 +283,6 @@ public class MyCanvas extends JPanel implements MouseListener, MouseMotionListen
|
|
|
x = e.getX();
|
|
|
y = e.getY();
|
|
|
dragging = false;
|
|
|
- tempCps.setPosition(e.getX() - controller.getScaleDiv2(), e.getY() - controller.getScaleDiv2());
|
|
|
}
|
|
|
|
|
|
// Rightclick List
|
|
@@ -297,6 +296,7 @@ public class MyCanvas extends JPanel implements MouseListener, MouseMotionListen
|
|
|
}
|
|
|
|
|
|
doMark = false;
|
|
|
+ controller.calculateStateForTimeStep(model.getCurIteration());
|
|
|
repaint();
|
|
|
}
|
|
|
|
|
@@ -413,7 +413,6 @@ public class MyCanvas extends JPanel implements MouseListener, MouseMotionListen
|
|
|
}
|
|
|
if (newEdge) {
|
|
|
e = new CpsEdge(cps, tempCps);
|
|
|
- controller.calculateStateForTimeStep(model.getCurIteration());
|
|
|
controller.AddEdgeOnCanvas(e);
|
|
|
}
|
|
|
}
|