Преглед на файлове

Merge pull request #1821 from Areloch/platformgenericmenucatch

Sanity check for if the GuiPlatformGenericMenuBar class
Areloch преди 8 години
родител
ревизия
1e89337825
променени са 2 файла, в които са добавени 38 реда и са изтрити 2 реда
  1. 19 1
      Templates/Empty/game/tools/gui/guiPlatformGenericMenubar.ed.cs
  2. 19 1
      Templates/Full/game/tools/gui/guiPlatformGenericMenubar.ed.cs

+ 19 - 1
Templates/Empty/game/tools/gui/guiPlatformGenericMenubar.ed.cs

@@ -1 +1,19 @@
-exec("./guiPlatformGenericMenubar.ed.gui");
+if(isClass(GuiPlatformGenericMenuBar))
+{
+   exec("./guiPlatformGenericMenubar.ed.gui");
+}
+else
+{
+   %guiContent = new GuiControl(PlatformGenericMenubar) {
+      profile = "GuiModelessDialogProfile";
+      
+      new GuiControl()
+      {
+         internalName = "menubar";
+         extent = "1024 20";
+         minExtent = "320 20";
+         horizSizing = "width";
+         profile = "GuiMenuBarProfile";
+      };
+   };
+}

+ 19 - 1
Templates/Full/game/tools/gui/guiPlatformGenericMenubar.ed.cs

@@ -1 +1,19 @@
-exec("./guiPlatformGenericMenubar.ed.gui");
+if(isClass(GuiPlatformGenericMenuBar))
+{
+   exec("./guiPlatformGenericMenubar.ed.gui");
+}
+else
+{
+   %guiContent = new GuiControl(PlatformGenericMenubar) {
+      profile = "GuiModelessDialogProfile";
+      
+      new GuiControl()
+      {
+         internalName = "menubar";
+         extent = "1024 20";
+         minExtent = "320 20";
+         horizSizing = "width";
+         profile = "GuiMenuBarProfile";
+      };
+   };
+}