summaryrefslogtreecommitdiff
path: root/indra/llui/llmenugl.cpp
diff options
context:
space:
mode:
authorRichard Nelson <richard@lindenlab.com>2007-02-17 03:02:16 +0000
committerRichard Nelson <richard@lindenlab.com>2007-02-17 03:02:16 +0000
commit73bc0fb42b5bcd80030d9f30d5cb57ec2397ba08 (patch)
treee7c0b2e22d4719123fd688e49a16b76a084c3f77 /indra/llui/llmenugl.cpp
parent12ac04231b8d358e70c830f7958f7efbc0f7c0d1 (diff)
merge -r 56779:58057 /branches/selection_management
Diffstat (limited to 'indra/llui/llmenugl.cpp')
-rw-r--r--indra/llui/llmenugl.cpp18
1 files changed, 12 insertions, 6 deletions
diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp
index 6ec0719ad5..7aaa306f05 100644
--- a/indra/llui/llmenugl.cpp
+++ b/indra/llui/llmenugl.cpp
@@ -385,11 +385,7 @@ void LLMenuItemGL::doIt( void )
{
// close all open menus by default
// if parent menu is actually visible (and we are not triggering menu item via accelerator)
- // HACK: do not call hidemenus() from a pie menu item, as most pie menu operations
- // assume that the thing you clicked on stays selected (parcel and/or object) after the
- // pie menu is gone --RN
- if (getMenu()->getWidgetType() != WIDGET_TYPE_PIE_MENU
- && !getMenu()->getTornOff()
+ if (!getMenu()->getTornOff()
&& getMenu()->getVisible())
{
LLMenuGL::sMenuContainer->hideMenus();
@@ -3283,7 +3279,7 @@ void LLPieMenuBranch::doIt( void )
S32 center_y;
parent->localPointToScreen(rect.getWidth() / 2, rect.getHeight() / 2, &center_x, &center_y);
- parent->hide(TRUE);
+ parent->hide(FALSE);
mBranch->show( center_x, center_y, FALSE );
}
@@ -3473,6 +3469,11 @@ BOOL LLPieMenu::handleMouseDown( S32 x, S32 y, MASK mask )
// to make sure it's within the item's rectangle
handled = item->handleMouseDown( 0, 0, mask );
}
+ else if (!mRightMouseDown)
+ {
+ // call hidemenus to make sure transient selections get cleared
+ ((LLMenuHolderGL*)getParent())->hideMenus();
+ }
// always handle mouse down as mouse up will close open menus
return handled;
@@ -3546,6 +3547,11 @@ BOOL LLPieMenu::handleMouseUp( S32 x, S32 y, MASK mask )
hide(TRUE);
}
}
+ else if (!mRightMouseDown)
+ {
+ // call hidemenus to make sure transient selections get cleared
+ ((LLMenuHolderGL*)getParent())->hideMenus();
+ }
if (handled)
{