diff options
author | Andrew Productengine <adyukov@productengine.com> | 2010-12-30 20:18:00 +0200 |
---|---|---|
committer | Andrew Productengine <adyukov@productengine.com> | 2010-12-30 20:18:00 +0200 |
commit | 2b44c8919f7e0ed58c7ae1ee782d8ff419382c03 (patch) | |
tree | a2f3f72c4ab51df4184c949b35c58cc0a2fbfb9e /indra | |
parent | e70ca1c391d0338b7a1cccd1d02e4532268e65f7 (diff) |
STORM-823 FIXED Fixed Tab Key not working properly in floaters.
Bug was caused by not fiding focus root in LLUICtrl::findRootMostFocusRoot() when tab was pressed in floaters. When it was not found, LLPanel::handleKeyHere() didn't move focus to the next control.
Floaters had erroneous behaviour because of focus_root xml param: though value of focus root was set with setFocusRoot() in floater's constructor , later it was overwritten in LLFloater::initFloaterXML() with value from xml again.
This problem was introduced in af49c237b0f9 - there focus root was moved to xml.
- To fix the problem, setFocusRoot() call was added after initFromParams() in LLFloater::initFloaterXML() to set proper value of focus root after overwriting it from xml.
The drawback of the fix is that focus_root param is ignored by floaters and its value is determined depending on chrome, as it did before but the only other way to fix this problem would be to set the param in xml manually for each existing floater, and do it for each new floater added to viewer.
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llui/llfloater.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/indra/llui/llfloater.cpp b/indra/llui/llfloater.cpp index 1265733bf5..d30697e178 100644 --- a/indra/llui/llfloater.cpp +++ b/indra/llui/llfloater.cpp @@ -2910,7 +2910,9 @@ bool LLFloater::initFloaterXML(LLXMLNodePtr node, LLView *parent, const std::str params.from_xui = true; applyXUILayout(params, parent); initFromParams(params); - + // chrome floaters don't take focus at all + setFocusRoot(!getIsChrome()); + initFloater(params); LLMultiFloater* last_host = LLFloater::getFloaterHost(); |