EXT-7593 FIXED Added passing focus to the selected outfit tab when My Outfits tab is open.

- Removed "tab_stop" from outfit tabs to prevent passing focus to a tab chosen by default from LLUICtrl::focusFirstItem(). Besides the order of passing focus between outfit tabs by pressing "Tab" was undetermined.
- Had to remove const from the return of LLAccordionCtrl::getSelectedTab() to use the returned pointer for setting focus.

Reviewed by Neal Orman at https://codereview.productengine.com/secondlife/r/846/.

--HG--
branch : product-engine
meow-7.2.2
Sergei Litovchuk 2010-08-09 15:23:00 +03:00
parent 55c887225f
commit 7bce6580dc
3 changed files with 8 additions and 1 deletions

View File

@ -139,7 +139,7 @@ public:
*/
const LLAccordionCtrlTab* getExpandedTab() const;
const LLAccordionCtrlTab* getSelectedTab() const { return mSelectedTab; }
LLAccordionCtrlTab* getSelectedTab() const { return mSelectedTab; }
bool getFitParent() const {return mFitParent;}

View File

@ -403,6 +403,12 @@ void LLOutfitsList::onOpen(const LLSD& /*info*/)
mIsInitialized = true;
}
LLAccordionCtrlTab* selected_tab = mAccordion->getSelectedTab();
if (!selected_tab) return;
// Pass focus to the selected outfit tab.
selected_tab->showAndFocusHeader();
}
void LLOutfitsList::refreshList(const LLUUID& category_id)

View File

@ -9,6 +9,7 @@
layout="topleft"
name="Mockup Tab"
selection_enabled="true"
tab_stop="false"
title="Mockup Tab"
translate="false"
width="0">