Fix for EXT-2571 to accommodate accordion panels

--HG--
branch : avatar-pipeline
meow-7.2.2
Brad Payne (Vir Linden) 2009-11-24 14:37:48 -05:00
parent e1cd91de4e
commit fc6cfc27be
3 changed files with 18 additions and 2 deletions

View File

@ -2346,8 +2346,12 @@ bool isInOutfitsSidePanel(LLPanel *panel)
LLInventoryPanel *my_panel = dynamic_cast<LLInventoryPanel*>(panel);
LLPanelOutfitsInventory *outfit_panel =
dynamic_cast<LLPanelOutfitsInventory*>(LLSideTray::getInstance()->getPanel("panel_outfits_inventory"));
LLInventoryPanel *outfit_inv_panel = outfit_panel ? outfit_panel->getActivePanel(): NULL;
return (my_panel && (my_panel == outfit_inv_panel));
if (!outfit_panel)
return false;
return outfit_panel->isAccordionPanel(my_panel);
//LLInventoryPanel *outfit_inv_panel = outfit_panel ? outfit_panel->getActivePanel(): NULL;
//return (my_panel && (my_panel == outfit_inv_panel));
}
void LLFolderBridge::folderOptionsMenu()

View File

@ -398,3 +398,14 @@ LLInventoryPanel* LLPanelOutfitsInventory::getActivePanel()
return mActivePanel;
}
bool LLPanelOutfitsInventory::isAccordionPanel(LLInventoryPanel *panel)
{
for(accordionpanels_vec_t::iterator it = mAccordionPanels.begin();
it != mAccordionPanels.end();
++it)
{
if (*it == panel)
return true;
}
return false;
}

View File

@ -78,6 +78,7 @@ public:
//////////////////////////////////////////////////////////////////////////////////
// Accordion //
LLInventoryPanel* getActivePanel();
bool isAccordionPanel(LLInventoryPanel *panel);
protected:
void initAccordionPanels();