X-Git-Url: https://mograsim.net/gitweb/?a=blobdiff_plain;f=net.mograsim.logic.model%2Fsrc%2Fnet%2Fmograsim%2Flogic%2Fmodel%2Fserializing%2FIndirectGUIComponentCreator.java;h=c6d1529f08ef97692da0571d49c7e61d2ac43416;hb=6e4cba5f4efabd7c069f53fbf41336ee1c7db402;hp=2ac2c47597bbe96b1ae2f0122608c1bb9ccc5da5;hpb=45941345b94530390abe953aab4e78135d4f0742;p=Mograsim.git diff --git a/net.mograsim.logic.model/src/net/mograsim/logic/model/serializing/IndirectGUIComponentCreator.java b/net.mograsim.logic.model/src/net/mograsim/logic/model/serializing/IndirectGUIComponentCreator.java index 2ac2c475..c6d1529f 100644 --- a/net.mograsim.logic.model/src/net/mograsim/logic/model/serializing/IndirectGUIComponentCreator.java +++ b/net.mograsim.logic.model/src/net/mograsim/logic/model/serializing/IndirectGUIComponentCreator.java @@ -15,7 +15,6 @@ import com.google.gson.JsonObject; import net.mograsim.logic.model.model.ViewModelModifiable; import net.mograsim.logic.model.model.components.GUIComponent; import net.mograsim.logic.model.model.components.submodels.SubmodelComponent; -import net.mograsim.logic.model.snippets.CodeSnippetSupplier; import net.mograsim.logic.model.util.JsonHandler; public class IndirectGUIComponentCreator @@ -72,9 +71,9 @@ public class IndirectGUIComponentCreator return standardComponentIDsUnmodifiable; } - public static void setComponentSupplier(String className, ComponentSupplier componentSupplier) + public static void setComponentSupplier(String id, ComponentSupplier componentSupplier) { - componentSuppliers.put(className, componentSupplier); + componentSuppliers.put(id, componentSupplier); } public static GUIComponent createComponent(ViewModelModifiable model, String id) @@ -213,7 +212,7 @@ public class IndirectGUIComponentCreator private static void tryLoadResourceLoader(String loaderClassName) { - CodeSnippetSupplier.tryInvokeStaticInitializer(loaderClassName, "Error loading resoruce loader %s: %s\n"); + ReflectionHelper.tryInvokeStaticInitializer(loaderClassName, "Error loading resoruce loader %s: %s\n"); } public static interface ComponentSupplier