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

Method OnInitialise

Tools/EditorFramework/ListBoxDataControl.cpp:23–46  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

21 }
22
23 void ListBoxDataControl::OnInitialise(Control* _parent, MyGUI::Widget* _place, std::string_view _layoutName)
24 {
25 Control::OnInitialise(_parent, _place, _layoutName);
26
27 mListBox = mMainWidget->castType<MyGUI::ListBox>(false);
28
29 assignWidget(mContextMenu, "ContextMenu", false);
30 mContextMenu->setVisible(false);
31
32 if (mListBox != nullptr)
33 {
34 mListBox->eventListChangePosition +=
35 MyGUI::newDelegate(this, &ListBoxDataControl::notifyListChangePosition);
36 mListBox->eventNotifyItem += MyGUI::newDelegate(this, &ListBoxDataControl::notifyItem);
37 }
38
39 mTextFieldControl = new TextFieldControl();
40 mTextFieldControl->Initialise();
41 mTextFieldControl->eventEndDialog.connect(this, &ListBoxDataControl::notifyEndDialog);
42
43 assignWidget(mHelpPanel, "HelpPanel", false, false);
44
45 mColourName = "ColourError";
46 }
47
48 void ListBoxDataControl::notifyListChangePosition(MyGUI::ListBox* _sender, size_t _index)
49 {

Callers

nothing calls this directly

Calls 5

assignWidgetFunction · 0.85
newDelegateFunction · 0.85
setVisibleMethod · 0.45
InitialiseMethod · 0.45
connectMethod · 0.45

Tested by

no test coverage detected