Browse Source

Prevent losing focus in modal window due to a click on emptiness.

Yao Wei Tjong 姚伟忠 11 years ago
parent
commit
2de4129fec
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Source/Engine/UI/UI.cpp

+ 1 - 1
Source/Engine/UI/UI.cpp

@@ -1023,7 +1023,7 @@ void UI::ProcessClickBegin(const IntVector2& cursorPos, int button, int buttons,
                 dragBeginTimer_.Reset();
             }
         }
-        else
+        else if (!HasModalElement())
         {
             // If clicked over no element, or a disabled element, lose focus
             SetFocusElement(0);