X-Git-Url: https://mograsim.net/gitweb/?a=blobdiff_plain;f=net.mograsim.logic.model.am2900%2Fsrc%2Fnet%2Fmograsim%2Flogic%2Fmodel%2Fexamples%2FFusionNotWorkingTest.java;h=eb8165f50ee219d154dc1c0b688ed4736e841bbf;hb=9af4c63c9f80205cb016568cae4823e1d42b6b30;hp=c13ec98f4134edd8d0563186acfb8ecd98003039;hpb=e104b507f81eebed56d923d5b0629f72d68d8b5a;p=Mograsim.git diff --git a/net.mograsim.logic.model.am2900/src/net/mograsim/logic/model/examples/FusionNotWorkingTest.java b/net.mograsim.logic.model.am2900/src/net/mograsim/logic/model/examples/FusionNotWorkingTest.java index c13ec98f..eb8165f5 100644 --- a/net.mograsim.logic.model.am2900/src/net/mograsim/logic/model/examples/FusionNotWorkingTest.java +++ b/net.mograsim.logic.model.am2900/src/net/mograsim/logic/model/examples/FusionNotWorkingTest.java @@ -1,13 +1,8 @@ package net.mograsim.logic.model.examples; -import java.util.concurrent.atomic.AtomicReference; - import net.haspamelodica.swt.helper.gcs.GeneralGC; import net.haspamelodica.swt.helper.swtobjectwrappers.Rectangle; -import net.mograsim.logic.core.timeline.TimelineEventHandler; -import net.mograsim.logic.model.LogicUICanvas; import net.mograsim.logic.model.SimpleLogicUIStandalone; -import net.mograsim.logic.model.SimpleLogicUIStandalone.VisualisationObjects; import net.mograsim.logic.model.model.ViewModelModifiable; import net.mograsim.logic.model.serializing.DeserializedSubmodelComponent; import net.mograsim.logic.model.serializing.IdentifierGetter; @@ -18,7 +13,7 @@ public class FusionNotWorkingTest { public static void main(String[] args) { - SimpleLogicUIStandalone.executeVisualisation(FusionNotWorkingTest::create, FusionNotWorkingTest::beforeRun); + SimpleLogicUIStandalone.executeVisualisation(FusionNotWorkingTest::create); } public static void create(ViewModelModifiable model) @@ -43,18 +38,4 @@ public class FusionNotWorkingTest } }); } - - public static void beforeRun(VisualisationObjects vis) - { - // TODO workaround for rendering bug - AtomicReference functionRef = new AtomicReference<>(); - LogicUICanvas logicUICanvas = vis.gui.getLogicUICanvas(); - TimelineEventHandler function = e -> - { - logicUICanvas.redrawThreadsafe(); - vis.timeline.addEvent(functionRef.get(), 50); - }; - functionRef.set(function); - vis.timeline.addEvent(function, 0); - } } \ No newline at end of file