diff options
Diffstat (limited to 'indra/llui/llmenugl.cpp')
-rw-r--r-- | indra/llui/llmenugl.cpp | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp index 76fd789bec..4264028338 100644 --- a/indra/llui/llmenugl.cpp +++ b/indra/llui/llmenugl.cpp @@ -1363,6 +1363,9 @@ public: virtual BOOL handleKeyHere(KEY key, MASK mask); virtual BOOL handleAcceleratorKey(KEY key, MASK mask); + + virtual void onFocusLost(); + virtual void setFocus(BOOL b); }; LLMenuItemBranchDownGL::LLMenuItemBranchDownGL( const Params& p) : @@ -1517,6 +1520,21 @@ BOOL LLMenuItemBranchDownGL::handleAcceleratorKey(KEY key, MASK mask) return handled; } +void LLMenuItemBranchDownGL::onFocusLost() +{ + // needed for tab-based selection + LLMenuItemBranchGL::onFocusLost(); + LLMenuGL::setKeyboardMode(FALSE); + setHighlight(FALSE); +} + +void LLMenuItemBranchDownGL::setFocus(BOOL b) +{ + // needed for tab-based selection + LLMenuItemBranchGL::setFocus(b); + LLMenuGL::setKeyboardMode(b); + setHighlight(b); +} BOOL LLMenuItemBranchDownGL::handleKeyHere(KEY key, MASK mask) { @@ -3942,8 +3960,8 @@ void LLTearOffMenu::draw() { // animate towards target height reshape(getRect().getWidth(), llceil(lerp((F32)getRect().getHeight(), (F32)mTargetHeight, LLSmoothInterpolation::getInterpolant(0.05f)))); - mMenu->needsArrange(); } + mMenu->needsArrange(); LLFloater::draw(); } |