summaryrefslogtreecommitdiff
path: root/indra/newview/llagent.cpp
diff options
context:
space:
mode:
authorErik Kundiman <erik@megapahit.org>2025-07-03 21:25:03 +0800
committerErik Kundiman <erik@megapahit.org>2025-07-03 21:25:03 +0800
commit9dee269eacd32c48627d3fcc243104a56f021bbc (patch)
treeb6418c111051e1ccebf0553e7ff667f917ea4c8d /indra/newview/llagent.cpp
parentfa7a4a38d8e66121116d91d947c4ec807822912e (diff)
parentbca9ba9b7940f9e32fe9dd25fb64fa4f2fb407db (diff)
Merge tag 'Second_Life_Project#bca9ba9b-glTF_Mesh_Import' into gltf_mesh_import
Diffstat (limited to 'indra/newview/llagent.cpp')
-rw-r--r--indra/newview/llagent.cpp13
1 files changed, 8 insertions, 5 deletions
diff --git a/indra/newview/llagent.cpp b/indra/newview/llagent.cpp
index f7b48d25f2..9ce14eb0ab 100644
--- a/indra/newview/llagent.cpp
+++ b/indra/newview/llagent.cpp
@@ -3477,11 +3477,14 @@ void LLAgent::initOriginGlobal(const LLVector3d &origin_global)
bool LLAgent::leftButtonGrabbed() const
{
- const bool camera_mouse_look = gAgentCamera.cameraMouselook();
- return (!camera_mouse_look && mControlsTakenCount[CONTROL_LBUTTON_DOWN_INDEX] > 0)
- || (camera_mouse_look && mControlsTakenCount[CONTROL_ML_LBUTTON_DOWN_INDEX] > 0)
- || (!camera_mouse_look && mControlsTakenPassedOnCount[CONTROL_LBUTTON_DOWN_INDEX] > 0)
- || (camera_mouse_look && mControlsTakenPassedOnCount[CONTROL_ML_LBUTTON_DOWN_INDEX] > 0);
+ if (gAgentCamera.cameraMouselook())
+ {
+ return mControlsTakenCount[CONTROL_ML_LBUTTON_DOWN_INDEX] > 0;
+ }
+ else
+ {
+ return mControlsTakenCount[CONTROL_LBUTTON_DOWN_INDEX] > 0;
+ }
}
bool LLAgent::rotateGrabbed() const