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

Method executeCommand

Tools/EditorFramework/CommandManager.cpp:26–50  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

24 }
25
26 bool CommandManager::executeCommand(const MyGUI::UString& _command)
27 {
28 bool result = false;
29 MyGUI::UString command = _command;
30 size_t index = _command.find('.');
31 if (index != MyGUI::UString::npos)
32 {
33 command = _command.substr(0, index);
34 mData = _command.substr(index + 1);
35 }
36
37 EventType* event = getEvent(command);
38 if (event != nullptr)
39 {
40 event->operator()(command, result);
41 }
42 else
43 {
44 MYGUI_LOG(Warning, "Command '" << command << "' not found");
45 }
46
47 mData.clear();
48
49 return result;
50 }
51
52 void CommandManager::setCommandData(const MyGUI::UString& _data)
53 {

Callers 15

updateCaptionMethod · 0.45
onFileDropMethod · 0.45
onWindowCloseMethod · 0.45
command_QuitAppMethod · 0.45
updateCaptionMethod · 0.45
notifyPopupMenuAcceptMethod · 0.45
updateCaptionMethod · 0.45
updateMenuMethod · 0.45
onFileDropMethod · 0.45
onWindowCloseMethod · 0.45
command_QuitAppMethod · 0.45

Calls 4

substrMethod · 0.80
findMethod · 0.45
operator()Method · 0.45
clearMethod · 0.45

Tested by

no test coverage detected