diff --git a/src/guiengine/widgets/text_box_widget.cpp b/src/guiengine/widgets/text_box_widget.cpp index ef0b5bcfd..e4bd5c5e0 100644 --- a/src/guiengine/widgets/text_box_widget.cpp +++ b/src/guiengine/widgets/text_box_widget.cpp @@ -146,8 +146,7 @@ void TextBoxWidget::unfocused(const int playerID, Widget* new_focus) setWithinATextBox(false); - if (new_focus != NULL) - GUIEngine::getGUIEnv()->setFocus(new_focus->getIrrlichtElement()); + GUIEngine::getGUIEnv()->removeFocus(m_element); } // -----------------------------------------------------------------------------