CFocusableHelper.cpp 573 B

12345678910111213141516171819202122
  1. /*
  2. * CFocusableHelper.cpp, part of VCMI engine
  3. *
  4. * Authors: listed in file AUTHORS in main folder
  5. *
  6. * License: GNU General Public License v2.0 or later
  7. * Full text of license available in license.txt file, in main folder
  8. *
  9. */
  10. #include "StdInc.h"
  11. #include "CFocusableHelper.h"
  12. #include "../Global.h"
  13. #include "widgets/TextControls.h"
  14. void removeFocusFromActiveInput()
  15. {
  16. if(CFocusable::inputWithFocus == nullptr)
  17. return;
  18. CFocusable::inputWithFocus->focus = false;
  19. CFocusable::inputWithFocus->redraw();
  20. CFocusable::inputWithFocus = nullptr;
  21. }