summaryrefslogtreecommitdiff
path: root/indra/llwindow/llwindowmacosx.cpp
diff options
context:
space:
mode:
authorMnikolenko ProductEngine <mnikolenko@productengine.com>2019-07-19 13:40:17 +0300
committerMnikolenko ProductEngine <mnikolenko@productengine.com>2019-07-19 13:40:17 +0300
commitc5bcb31d00cdac597ce6e406c253ba456e9436c8 (patch)
tree617493f1a201e69d40597eccb9f8e3365b237f58 /indra/llwindow/llwindowmacosx.cpp
parenta0bf70b41d84c50da081917f0ec842cca973f45b (diff)
SL-11592 [Mac] Fixed mouse buttons ids for correct handling.
Diffstat (limited to 'indra/llwindow/llwindowmacosx.cpp')
-rw-r--r--indra/llwindow/llwindowmacosx.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp
index 6749b3be3b..d9b95d311a 100644
--- a/indra/llwindow/llwindowmacosx.cpp
+++ b/indra/llwindow/llwindowmacosx.cpp
@@ -426,13 +426,14 @@ void callOtherMouseDown(float *pos, MASK mask, int button)
gWindowImplementation->getMouseDeltas(deltas);
outCoords.mX += deltas[0];
outCoords.mY += deltas[1];
- if (button == 3)
+
+ if (button == 2)
{
gWindowImplementation->getCallbacks()->handleMiddleMouseDown(gWindowImplementation, outCoords, mask);
}
else
{
- gWindowImplementation->getCallbacks()->handleOtherMouseDown(gWindowImplementation, outCoords, mask, button);
+ gWindowImplementation->getCallbacks()->handleOtherMouseDown(gWindowImplementation, outCoords, mask, button + 1);
}
}
@@ -445,13 +446,13 @@ void callOtherMouseUp(float *pos, MASK mask, int button)
gWindowImplementation->getMouseDeltas(deltas);
outCoords.mX += deltas[0];
outCoords.mY += deltas[1];
- if (button == 3)
+ if (button == 2)
{
gWindowImplementation->getCallbacks()->handleMiddleMouseUp(gWindowImplementation, outCoords, mask);
}
else
{
- gWindowImplementation->getCallbacks()->handleOtherMouseUp(gWindowImplementation, outCoords, mask, button);
+ gWindowImplementation->getCallbacks()->handleOtherMouseUp(gWindowImplementation, outCoords, mask, button + 1);
}
}