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

Method injectKeyPress

Tools/ImageEditor/Application.cpp:324–334  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

322 }
323
324 void Application::injectKeyPress(MyGUI::KeyCode _key, MyGUI::Char _text)
325 {
326 if (MyGUI::Gui::getInstancePtr() == nullptr)
327 return;
328
329 MyGUI::InputManager& input = MyGUI::InputManager::getInstance();
330
331 bool controlPressed = input.isControlPressed() || input.isMetaPressed();
332 if (!HotKeyManager::getInstance().onKeyEvent(true, input.isShiftPressed(), controlPressed, _key))
333 input.injectKeyPress(_key, _text);
334 }
335
336 void Application::command_QuitApp(const MyGUI::UString& _commandName, bool& _result)
337 {

Callers

nothing calls this directly

Calls 5

getInstancePtrFunction · 0.85
isControlPressedMethod · 0.80
isMetaPressedMethod · 0.80
onKeyEventMethod · 0.80
isShiftPressedMethod · 0.80

Tested by

no test coverage detected