diff options
author | andreykproductengine <none@none> | 2017-01-04 10:51:17 +0200 |
---|---|---|
committer | andreykproductengine <none@none> | 2017-01-04 10:51:17 +0200 |
commit | 7c70236fe0f24ede06022fcafee53e1815804ce3 (patch) | |
tree | 3dd1c3744fde592ee28f2697417683301ce03bb1 /indra/newview | |
parent | 892d3207d6f6d4506a6675a917b374651fa7f9c4 (diff) |
MAINT-838 Removing obsolete and malfunctioning leftClickShowMenu
Diffstat (limited to 'indra/newview')
-rw-r--r-- | indra/newview/app_settings/settings.xml | 2 | ||||
-rw-r--r-- | indra/newview/lltoolpie.cpp | 65 |
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, |