Arma Reforger Explorer  1.1.0.42
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
EditorMenuBase.c
Go to the documentation of this file.
1 
8 {
10  //--- Actions
11 
16  MenuBase OpenDialog(ChimeraMenuPreset preset)
17  {
18  if (GetManager().FindMenuByPreset(preset)) return null; //--- Already opened
19  return GetManager().OpenDialog(preset);
20  }
21 
26  MenuBase OpenMenu(ChimeraMenuPreset preset)
27  {
28  if (GetManager().FindMenuByPreset(preset)) return null; //--- Already opened
29  return GetManager().OpenMenu(preset);
30  }
31 
35  void CloseSelf()
36  {
37  GetManager().CloseMenu(this);
38  }
39 
44  protected void DeleteAllChildWidgets(Widget parentWidget)
45  {
46  while (parentWidget.GetChildren())
47  {
48  delete parentWidget.GetChildren();
49  }
50  }
51 
53  //--- Getters
54 
59  Widget GetWidgetByName(string widgetName)
60  {
61  Widget root = GetRootWidget();
62  if (!root) return null;
63 
64  WorkspaceWidget workspace = GetGame().GetWorkspace();
65  if (!workspace) return null;
66 
67  return root.FindAnyWidget(widgetName);
68  }
69 };
GetGame
ArmaReforgerScripted GetGame()
Definition: game.c:1424
GetRootWidget
Widget GetRootWidget()
Definition: SCR_UITaskManagerComponent.c:160
MenuRootBase
Definition: MenuRootBase.c:6
EditorMenuBase
Definition: EditorMenuBase.c:7
ChimeraMenuPreset
ChimeraMenuPreset
Menu presets.
Definition: ChimeraMenuBase.c:3