MCPcopy Create free account
hub / github.com/MyGUI/mygui / OnInitialise

Method OnInitialise

Tools/EditorFramework/MainMenuControl.cpp:21–36  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19 }
20
21 void MainMenuControl::OnInitialise(Control* _parent, MyGUI::Widget* _place, std::string_view _layoutName)
22 {
23 Control::OnInitialise(_parent, _place, _layoutName);
24
25 assignWidget(mMainMenu, "MainMenu");
26
27 mScaleMenu = mMainMenu->findItemById("Scale");
28
29 CommandManager::getInstance()
30 .getEvent("Command_UpdateAppCaption")
31 ->connect(this, &MainMenuControl::command_UpdateAppCaption);
32
33 mMainMenu->eventMenuCtrlAccept += MyGUI::newDelegate(this, &MainMenuControl::notifyMenuCtrlAccept);
34
35 updateRecentFilesMenu();
36 }
37
38 void MainMenuControl::notifyMenuCtrlAccept(MyGUI::MenuControl* _sender, MyGUI::MenuItem* _item)
39 {

Callers

nothing calls this directly

Calls 5

assignWidgetFunction · 0.85
newDelegateFunction · 0.85
findItemByIdMethod · 0.80
connectMethod · 0.45
getEventMethod · 0.45

Tested by

no test coverage detected