summaryrefslogtreecommitdiff
path: root/indra/llui/llpanel.cpp
diff options
context:
space:
mode:
authorLeyla Farazha <leyla@lindenlab.com>2010-01-11 16:05:42 -0800
committerLeyla Farazha <leyla@lindenlab.com>2010-01-11 16:05:42 -0800
commit1a35fe8725d4a55ef1e1b07d59db8e8d0db5e6bf (patch)
tree04895ab55cf6ab33f1412131c76a71f4f4d549d4 /indra/llui/llpanel.cpp
parent8440d99e4498882dfc61459a91eba746ad717000 (diff)
parent2aaa7971945823f53f0a01028036c37361bcfa17 (diff)
Merge
Diffstat (limited to 'indra/llui/llpanel.cpp')
-rw-r--r--indra/llui/llpanel.cpp23
1 files changed, 18 insertions, 5 deletions
diff --git a/indra/llui/llpanel.cpp b/indra/llui/llpanel.cpp
index db32882438..143f19eea6 100644
--- a/indra/llui/llpanel.cpp
+++ b/indra/llui/llpanel.cpp
@@ -43,6 +43,7 @@
#include "llerror.h"
#include "lltimer.h"
+#include "llaccordionctrltab.h"
#include "llbutton.h"
#include "llmenugl.h"
//#include "llstatusbar.h"
@@ -851,14 +852,26 @@ static LLPanel *childGetVisibleTabWithHelp(LLView *parent)
// look through immediate children first for an active tab with help
for (child = parent->getFirstChild(); child; child = parent->findNextSibling(child))
{
+ LLPanel *curTabPanel = NULL;
+
+ // do we have a tab container?
LLTabContainer *tab = dynamic_cast<LLTabContainer *>(child);
if (tab && tab->getVisible())
{
- LLPanel *curTabPanel = tab->getCurrentPanel();
- if (curTabPanel && !curTabPanel->getHelpTopic().empty())
- {
- return curTabPanel;
- }
+ curTabPanel = tab->getCurrentPanel();
+ }
+
+ // do we have an accordion tab?
+ LLAccordionCtrlTab* accordion = dynamic_cast<LLAccordionCtrlTab *>(child);
+ if (accordion && accordion->getDisplayChildren())
+ {
+ curTabPanel = dynamic_cast<LLPanel *>(accordion->getAccordionView());
+ }
+
+ // if we found a valid tab, does it have a help topic?
+ if (curTabPanel && !curTabPanel->getHelpTopic().empty())
+ {
+ return curTabPanel;
}
}