summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2017-01-04 19:47:04 +0200
committerAndrey Kleshchev <andreykproductengine@lindenlab.com>2017-01-04 19:47:04 +0200
commitb8973cb78a6375dee4257e481509487428452c60 (patch)
tree50fbb4a6f8cdee6d2153ecc33644e5fb255f7121 /indra
parent9edc5b10697e5a4c5af90362d8158f427735740a (diff)
parent7c70236fe0f24ede06022fcafee53e1815804ce3 (diff)
Merged in MAINT-838 (pull request #133)
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/app_settings/settings.xml2
-rw-r--r--indra/newview/lltoolpie.cpp65
2 files changed, 26 insertions, 41 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index 6d8b642d6f..8ddb421ac3 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -5376,7 +5376,7 @@
<key>LeftClickShowMenu</key>
<map>
<key>Comment</key>
- <string>Left click opens pie menu (FALSE = left click touches or grabs object)</string>
+ <string>Unused obsolete setting</string>
<key>Persist</key>
<integer>1</integer>
<key>Type</key>
diff --git a/indra/newview/lltoolpie.cpp b/indra/newview/lltoolpie.cpp
index e17651dc91..e79ce55854 100644
--- a/indra/newview/lltoolpie.cpp
+++ b/indra/newview/lltoolpie.cpp
@@ -338,56 +338,41 @@ BOOL LLToolPie::handleLeftClickPick()
// If left-click never selects or spawns a menu
// Eat the event.
- if (!gSavedSettings.getBOOL("LeftClickShowMenu"))
+
+ // mouse already released
+ if (!mMouseButtonDown)
{
- // mouse already released
- if (!mMouseButtonDown)
- {
- return true;
- }
+ return true;
+ }
- while( object && object->isAttachment() && !object->flagHandleTouch())
+ while (object && object->isAttachment() && !object->flagHandleTouch())
+ {
+ // don't pick avatar through hud attachment
+ if (object->isHUDAttachment())
{
- // don't pick avatar through hud attachment
- if (object->isHUDAttachment())
- {
- break;
- }
- object = (LLViewerObject*)object->getParent();
+ break;
}
- if (object && object == gAgentAvatarp && !gSavedSettings.getBOOL("ClickToWalk"))
- {
- // we left clicked on avatar, switch to focus mode
- mMouseButtonDown = false;
- LLToolMgr::getInstance()->setTransientTool(LLToolCamera::getInstance());
- gViewerWindow->hideCursor();
- LLToolCamera::getInstance()->setMouseCapture(TRUE);
- LLToolCamera::getInstance()->pickCallback(mPick);
- gAgentCamera.setFocusOnAvatar(TRUE, TRUE);
+ object = (LLViewerObject*)object->getParent();
+ }
+ if (object && object == gAgentAvatarp && !gSavedSettings.getBOOL("ClickToWalk"))
+ {
+ // we left clicked on avatar, switch to focus mode
+ mMouseButtonDown = false;
+ LLToolMgr::getInstance()->setTransientTool(LLToolCamera::getInstance());
+ gViewerWindow->hideCursor();
+ LLToolCamera::getInstance()->setMouseCapture(TRUE);
+ LLToolCamera::getInstance()->pickCallback(mPick);
+ gAgentCamera.setFocusOnAvatar(TRUE, TRUE);
- return TRUE;
- }
+ return TRUE;
+ }
//////////
// // Could be first left-click on nothing
// LLFirstUse::useLeftClickNoHit();
/////////
-
- // Eat the event
- return LLTool::handleMouseDown(x, y, mask);
- }
-
- if (gAgent.leftButtonGrabbed())
- {
- // if the left button is grabbed, don't put up the pie menu
- return LLTool::handleMouseDown(x, y, mask);
- }
-
- // Can't ignore children here.
- LLToolSelect::handleObjectSelection(mPick, FALSE, TRUE);
- // Spawn pie menu
- LLTool::handleRightMouseDown(x, y, mask);
- return TRUE;
+ // Eat the event
+ return LLTool::handleMouseDown(x, y, mask);
}
BOOL LLToolPie::useClickAction(MASK mask,