diff options
author | maxim@mnikolenko <maxim@mnikolenko> | 2013-01-18 14:19:26 +0200 |
---|---|---|
committer | maxim@mnikolenko <maxim@mnikolenko> | 2013-01-18 14:19:26 +0200 |
commit | a835361d7163801192283aba83bf70678b1ca4e0 (patch) | |
tree | a29b605265c3299c4b830a366254d24a58b9ca39 /indra/llui | |
parent | 3938f99b5ede5b87315fa18ca24d2deece28b34d (diff) | |
parent | a5813e72cfc989747df5724e28c0f25541b75ba5 (diff) |
Merge
Diffstat (limited to 'indra/llui')
-rw-r--r-- | indra/llui/llmenugl.cpp | 28 |
1 files changed, 21 insertions, 7 deletions
diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp index 93dc13475b..7dcc39950b 100644 --- a/indra/llui/llmenugl.cpp +++ b/indra/llui/llmenugl.cpp @@ -1751,16 +1751,18 @@ void LLMenuGL::setCanTearOff(BOOL tear_off) bool LLMenuGL::addChild(LLView* view, S32 tab_group) { - if (LLMenuGL* menup = dynamic_cast<LLMenuGL*>(view)) + LLMenuGL* menup = dynamic_cast<LLMenuGL*>(view); + if (menup) { - appendMenu(menup); - return true; + return appendMenu(menup); } - else if (LLMenuItemGL* itemp = dynamic_cast<LLMenuItemGL*>(view)) + + LLMenuItemGL* itemp = dynamic_cast<LLMenuItemGL*>(view); + if (itemp) { - append(itemp); - return true; + return append(itemp); } + return false; } @@ -1771,16 +1773,28 @@ bool LLMenuGL::addContextChild(LLView* view, S32 tab_group) { LLContextMenu* context = dynamic_cast<LLContextMenu*>(view); if (context) + { return appendContextSubMenu(context); + } LLMenuItemSeparatorGL* separator = dynamic_cast<LLMenuItemSeparatorGL*>(view); if (separator) + { return append(separator); + } LLMenuItemGL* item = dynamic_cast<LLMenuItemGL*>(view); if (item) + { return append(item); - + } + + LLMenuGL* menup = dynamic_cast<LLMenuGL*>(view); + if (menup) + { + return appendMenu(menup); + } + return false; } |