fixed a graphics bug occurring if the running model is restarted and this restart changes the graphic representation of the components.

This commit is contained in:
hneemann 2017-04-27 20:51:17 +02:00
parent 4a3c40278d
commit b25b7d0d54

View File

@ -807,8 +807,10 @@ public final class Main extends JFrame implements ClosingWindowListener.ConfirmS
modelCreator = new ModelCreator(circuitComponent.getCircuit(), library);
if (model != null)
if (model != null) {
model.close();
circuitComponent.getCircuit().clearState();
}
model = modelCreator.createModel(true);
model.setWindowPosManager(windowPosManager);