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

Method onKeySetFocus

MyGUIEngine/src/MyGUI_EditBox.cpp:260–281  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

258 }
259
260 void EditBox::onKeySetFocus(Widget* _old)
261 {
262 if (!mIsPressed)
263 {
264 mIsPressed = true;
265 updateEditState();
266
267 if (!mModeStatic)
268 {
269 if (mClientText != nullptr)
270 {
271 mCursorActive = true;
272 Gui::getInstance().eventFrameStart += newDelegate(this, &EditBox::frameEntered);
273 mClientText->setVisibleCursor(true);
274 mClientText->setSelectBackground(true);
275 mCursorTimer = 0;
276 }
277 }
278 }
279
280 Base::onKeySetFocus(_old);
281 }
282
283 void EditBox::onKeyLostFocus(Widget* _new)
284 {

Callers

nothing calls this directly

Calls 3

newDelegateFunction · 0.85
setVisibleCursorMethod · 0.80
setSelectBackgroundMethod · 0.80

Tested by

no test coverage detected