Speedup by changing redraw listener system
[Mograsim.git] / net.mograsim.logic.model / src / net / mograsim / logic / model / model / components / atomic / GUIManualSwitch.java
index e4c1833..611d341 100644 (file)
@@ -40,7 +40,7 @@ public class GUIManualSwitch extends GUIComponent
        public GUIManualSwitch(ViewModelModifiable model, String name)
        {
                super(model, name);
-               logicObs = (i) -> requestRedraw();
+               logicObs = (i) -> model.requestRedraw();
 
                setSize(width, height);
                addPin(this.outputPin = new Pin(this, "", 1, width, height / 2));