summaryrefslogtreecommitdiffstats
path: root/src/newt
diff options
context:
space:
mode:
Diffstat (limited to 'src/newt')
-rw-r--r--src/newt/classes/jogamp/newt/WindowImpl.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/newt/classes/jogamp/newt/WindowImpl.java b/src/newt/classes/jogamp/newt/WindowImpl.java
index f82f4b7d4..6b3fd7aa4 100644
--- a/src/newt/classes/jogamp/newt/WindowImpl.java
+++ b/src/newt/classes/jogamp/newt/WindowImpl.java
@@ -2030,9 +2030,12 @@ public abstract class WindowImpl implements Window, NEWTEventConsumer
lastMousePosition.setX(x);
lastMousePosition.setY(y);
}
- if(button<0||button>MouseEvent.BUTTON_NUMBER) {
+ if( 0 > button || button > MouseEvent.BUTTON_NUMBER ) {
throw new NativeWindowException("Invalid mouse button number" + button);
}
+ // Fixes Bug 571: X11 behavior, where the PRESSED button is not included in the native mask.
+ modifiers |= InputEvent.getButtonMask(button);
+
MouseEvent eClicked = null;
MouseEvent e = null;