From 184657530ab8dae197a015c219be14640379fc18 Mon Sep 17 00:00:00 2001 From: Julien Gouesse Date: Thu, 17 Jan 2013 21:06:59 +0100 Subject: Switches to JOGL 2.0 build 896 --- .../lib/jogl/gluegen-rt-natives-linux-amd64.jar | Bin 3538 -> 3542 bytes .../lib/jogl/gluegen-rt-natives-linux-i586.jar | Bin 3461 -> 3465 bytes .../jogl/gluegen-rt-natives-macosx-universal.jar | Bin 3972 -> 3976 bytes .../lib/jogl/gluegen-rt-natives-solaris-amd64.jar | Bin 4085 -> 4089 bytes .../lib/jogl/gluegen-rt-natives-solaris-i586.jar | Bin 3395 -> 3399 bytes .../lib/jogl/gluegen-rt-natives-windows-amd64.jar | Bin 6308 -> 6310 bytes .../lib/jogl/gluegen-rt-natives-windows-i586.jar | Bin 4450 -> 4453 bytes ardor3d-jogl/lib/jogl/gluegen-rt.jar | Bin 216362 -> 219526 bytes .../lib/jogl/jogl-all-natives-linux-amd64.jar | Bin 145724 -> 146502 bytes .../lib/jogl/jogl-all-natives-linux-i586.jar | Bin 144522 -> 145230 bytes .../lib/jogl/jogl-all-natives-macosx-universal.jar | Bin 329959 -> 330601 bytes .../lib/jogl/jogl-all-natives-solaris-amd64.jar | Bin 146280 -> 147059 bytes .../lib/jogl/jogl-all-natives-solaris-i586.jar | Bin 111608 -> 112284 bytes .../lib/jogl/jogl-all-natives-windows-amd64.jar | Bin 111515 -> 111896 bytes .../lib/jogl/jogl-all-natives-windows-i586.jar | Bin 135199 -> 135463 bytes ardor3d-jogl/lib/jogl/jogl-all.jar | Bin 4862080 -> 4778109 bytes .../lib/jogl/native/linux-amd64/libjogl_desktop.so | Bin 575592 -> 575592 bytes .../jogl/native/linux-amd64/libnativewindow_x11.so | Bin 27088 -> 31200 bytes .../lib/jogl/native/linux-amd64/libnewt.so | Bin 47704 -> 47704 bytes .../lib/jogl/native/linux-i586/libjogl_desktop.so | Bin 546200 -> 546200 bytes .../jogl/native/linux-i586/libnativewindow_x11.so | Bin 26176 -> 26184 bytes ardor3d-jogl/lib/jogl/native/linux-i586/libnewt.so | Bin 42640 -> 42640 bytes .../native/macosx-universal/libjogl_desktop.jnilib | Bin 1325480 -> 1325656 bytes .../macosx-universal/libnativewindow_macosx.jnilib | Bin 95376 -> 95376 bytes .../jogl/native/macosx-universal/libnewt.jnilib | Bin 168352 -> 168360 bytes .../jogl/native/solaris-amd64/libjogl_desktop.so | Bin 649296 -> 649584 bytes .../native/solaris-amd64/libnativewindow_x11.so | Bin 94040 -> 95528 bytes .../lib/jogl/native/solaris-amd64/libnewt.so | Bin 104488 -> 104472 bytes .../jogl/native/solaris-i586/libjogl_desktop.so | Bin 479360 -> 479584 bytes .../native/solaris-i586/libnativewindow_x11.so | Bin 22868 -> 24192 bytes .../lib/jogl/native/solaris-i586/libnewt.so | Bin 32488 -> 32472 bytes .../lib/jogl/native/windows-amd64/gluegen-rt.dll | Bin 14848 -> 14848 bytes .../lib/jogl/native/windows-amd64/jogl_desktop.dll | Bin 544768 -> 544768 bytes .../jogl/native/windows-amd64/nativewindow_awt.dll | Bin 14336 -> 14336 bytes .../native/windows-amd64/nativewindow_win32.dll | Bin 22016 -> 22016 bytes .../lib/jogl/native/windows-amd64/newt.dll | Bin 28160 -> 28160 bytes .../lib/jogl/native/windows-i586/gluegen-rt.dll | Bin 10752 -> 10752 bytes .../lib/jogl/native/windows-i586/jogl_desktop.dll | Bin 404992 -> 404992 bytes .../jogl/native/windows-i586/nativewindow_awt.dll | Bin 10240 -> 10240 bytes .../native/windows-i586/nativewindow_win32.dll | Bin 38912 -> 38912 bytes ardor3d-jogl/lib/jogl/native/windows-i586/newt.dll | Bin 45056 -> 45568 bytes .../ardor3d/input/jogl/JoglNewtMouseWrapper.java | 76 ++++++++++----------- 42 files changed, 38 insertions(+), 38 deletions(-) (limited to 'ardor3d-jogl') diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-amd64.jar b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-amd64.jar index 98177cc..9cafdfa 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-amd64.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-amd64.jar differ diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-i586.jar b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-i586.jar index 668bbbb..ec2c197 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-i586.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-linux-i586.jar differ diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-macosx-universal.jar b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-macosx-universal.jar index 11999bc..e473a81 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-macosx-universal.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-macosx-universal.jar differ diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-amd64.jar b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-amd64.jar index c9c75eb..746cda0 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-amd64.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-amd64.jar differ diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-i586.jar b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-i586.jar index ccc064d..7502047 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-i586.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-solaris-i586.jar differ diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-amd64.jar b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-amd64.jar index 43c1a95..a806e70 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-amd64.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-amd64.jar differ diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-i586.jar b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-i586.jar index b9aa134..f860ac8 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-i586.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt-natives-windows-i586.jar differ diff --git a/ardor3d-jogl/lib/jogl/gluegen-rt.jar b/ardor3d-jogl/lib/jogl/gluegen-rt.jar index a9957e6..312b559 100644 Binary files a/ardor3d-jogl/lib/jogl/gluegen-rt.jar and b/ardor3d-jogl/lib/jogl/gluegen-rt.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-amd64.jar b/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-amd64.jar index 0f914e2..3c1eca6 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-amd64.jar and b/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-amd64.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-i586.jar b/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-i586.jar index e969c9b..a6708ea 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-i586.jar and b/ardor3d-jogl/lib/jogl/jogl-all-natives-linux-i586.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all-natives-macosx-universal.jar b/ardor3d-jogl/lib/jogl/jogl-all-natives-macosx-universal.jar index 32f1567..b810a7c 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all-natives-macosx-universal.jar and b/ardor3d-jogl/lib/jogl/jogl-all-natives-macosx-universal.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-amd64.jar b/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-amd64.jar index cee93dd..de3bcc0 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-amd64.jar and b/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-amd64.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-i586.jar b/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-i586.jar index 8f2dc08..e29a4de 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-i586.jar and b/ardor3d-jogl/lib/jogl/jogl-all-natives-solaris-i586.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-amd64.jar b/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-amd64.jar index 8ca3682..2b85383 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-amd64.jar and b/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-amd64.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-i586.jar b/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-i586.jar index 1ff1289..ded00b2 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-i586.jar and b/ardor3d-jogl/lib/jogl/jogl-all-natives-windows-i586.jar differ diff --git a/ardor3d-jogl/lib/jogl/jogl-all.jar b/ardor3d-jogl/lib/jogl/jogl-all.jar index 977f5f1..9809443 100644 Binary files a/ardor3d-jogl/lib/jogl/jogl-all.jar and b/ardor3d-jogl/lib/jogl/jogl-all.jar differ diff --git a/ardor3d-jogl/lib/jogl/native/linux-amd64/libjogl_desktop.so b/ardor3d-jogl/lib/jogl/native/linux-amd64/libjogl_desktop.so index f91d7c6..5afbcec 100644 Binary files a/ardor3d-jogl/lib/jogl/native/linux-amd64/libjogl_desktop.so and b/ardor3d-jogl/lib/jogl/native/linux-amd64/libjogl_desktop.so differ diff --git a/ardor3d-jogl/lib/jogl/native/linux-amd64/libnativewindow_x11.so b/ardor3d-jogl/lib/jogl/native/linux-amd64/libnativewindow_x11.so index 53100af..bea6b09 100644 Binary files a/ardor3d-jogl/lib/jogl/native/linux-amd64/libnativewindow_x11.so and b/ardor3d-jogl/lib/jogl/native/linux-amd64/libnativewindow_x11.so differ diff --git a/ardor3d-jogl/lib/jogl/native/linux-amd64/libnewt.so b/ardor3d-jogl/lib/jogl/native/linux-amd64/libnewt.so index d757938..467496e 100644 Binary files a/ardor3d-jogl/lib/jogl/native/linux-amd64/libnewt.so and b/ardor3d-jogl/lib/jogl/native/linux-amd64/libnewt.so differ diff --git a/ardor3d-jogl/lib/jogl/native/linux-i586/libjogl_desktop.so b/ardor3d-jogl/lib/jogl/native/linux-i586/libjogl_desktop.so index 1fe60d5..15c8ffe 100644 Binary files a/ardor3d-jogl/lib/jogl/native/linux-i586/libjogl_desktop.so and b/ardor3d-jogl/lib/jogl/native/linux-i586/libjogl_desktop.so differ diff --git a/ardor3d-jogl/lib/jogl/native/linux-i586/libnativewindow_x11.so b/ardor3d-jogl/lib/jogl/native/linux-i586/libnativewindow_x11.so index 9e18ccd..7b30715 100644 Binary files a/ardor3d-jogl/lib/jogl/native/linux-i586/libnativewindow_x11.so and b/ardor3d-jogl/lib/jogl/native/linux-i586/libnativewindow_x11.so differ diff --git a/ardor3d-jogl/lib/jogl/native/linux-i586/libnewt.so b/ardor3d-jogl/lib/jogl/native/linux-i586/libnewt.so index 9d00b7d..78e32bf 100644 Binary files a/ardor3d-jogl/lib/jogl/native/linux-i586/libnewt.so and b/ardor3d-jogl/lib/jogl/native/linux-i586/libnewt.so differ diff --git a/ardor3d-jogl/lib/jogl/native/macosx-universal/libjogl_desktop.jnilib b/ardor3d-jogl/lib/jogl/native/macosx-universal/libjogl_desktop.jnilib index ebc22dc..b6662ac 100644 Binary files a/ardor3d-jogl/lib/jogl/native/macosx-universal/libjogl_desktop.jnilib and b/ardor3d-jogl/lib/jogl/native/macosx-universal/libjogl_desktop.jnilib differ diff --git a/ardor3d-jogl/lib/jogl/native/macosx-universal/libnativewindow_macosx.jnilib b/ardor3d-jogl/lib/jogl/native/macosx-universal/libnativewindow_macosx.jnilib index 9b5c146..20ed523 100644 Binary files a/ardor3d-jogl/lib/jogl/native/macosx-universal/libnativewindow_macosx.jnilib and b/ardor3d-jogl/lib/jogl/native/macosx-universal/libnativewindow_macosx.jnilib differ diff --git a/ardor3d-jogl/lib/jogl/native/macosx-universal/libnewt.jnilib b/ardor3d-jogl/lib/jogl/native/macosx-universal/libnewt.jnilib index 2396a03..fb75af1 100644 Binary files a/ardor3d-jogl/lib/jogl/native/macosx-universal/libnewt.jnilib and b/ardor3d-jogl/lib/jogl/native/macosx-universal/libnewt.jnilib differ diff --git a/ardor3d-jogl/lib/jogl/native/solaris-amd64/libjogl_desktop.so b/ardor3d-jogl/lib/jogl/native/solaris-amd64/libjogl_desktop.so index 956e497..82b8099 100644 Binary files a/ardor3d-jogl/lib/jogl/native/solaris-amd64/libjogl_desktop.so and b/ardor3d-jogl/lib/jogl/native/solaris-amd64/libjogl_desktop.so differ diff --git a/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnativewindow_x11.so b/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnativewindow_x11.so index 7bb9279..c6d2759 100644 Binary files a/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnativewindow_x11.so and b/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnativewindow_x11.so differ diff --git a/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnewt.so b/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnewt.so index 2b84891..28ec3ce 100644 Binary files a/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnewt.so and b/ardor3d-jogl/lib/jogl/native/solaris-amd64/libnewt.so differ diff --git a/ardor3d-jogl/lib/jogl/native/solaris-i586/libjogl_desktop.so b/ardor3d-jogl/lib/jogl/native/solaris-i586/libjogl_desktop.so index cb9a072..1c8bc54 100644 Binary files a/ardor3d-jogl/lib/jogl/native/solaris-i586/libjogl_desktop.so and b/ardor3d-jogl/lib/jogl/native/solaris-i586/libjogl_desktop.so differ diff --git a/ardor3d-jogl/lib/jogl/native/solaris-i586/libnativewindow_x11.so b/ardor3d-jogl/lib/jogl/native/solaris-i586/libnativewindow_x11.so index 9693dc2..e987b1b 100644 Binary files a/ardor3d-jogl/lib/jogl/native/solaris-i586/libnativewindow_x11.so and b/ardor3d-jogl/lib/jogl/native/solaris-i586/libnativewindow_x11.so differ diff --git a/ardor3d-jogl/lib/jogl/native/solaris-i586/libnewt.so b/ardor3d-jogl/lib/jogl/native/solaris-i586/libnewt.so index 3ab2e58..71a6b9e 100644 Binary files a/ardor3d-jogl/lib/jogl/native/solaris-i586/libnewt.so and b/ardor3d-jogl/lib/jogl/native/solaris-i586/libnewt.so differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-amd64/gluegen-rt.dll b/ardor3d-jogl/lib/jogl/native/windows-amd64/gluegen-rt.dll index 9ea63b1..f5a12e7 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-amd64/gluegen-rt.dll and b/ardor3d-jogl/lib/jogl/native/windows-amd64/gluegen-rt.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-amd64/jogl_desktop.dll b/ardor3d-jogl/lib/jogl/native/windows-amd64/jogl_desktop.dll index 2b27820..c3568c5 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-amd64/jogl_desktop.dll and b/ardor3d-jogl/lib/jogl/native/windows-amd64/jogl_desktop.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_awt.dll b/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_awt.dll index bf67563..2198ea1 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_awt.dll and b/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_awt.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_win32.dll b/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_win32.dll index 044d080..03e6fe1 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_win32.dll and b/ardor3d-jogl/lib/jogl/native/windows-amd64/nativewindow_win32.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-amd64/newt.dll b/ardor3d-jogl/lib/jogl/native/windows-amd64/newt.dll index aa7e2f9..696c626 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-amd64/newt.dll and b/ardor3d-jogl/lib/jogl/native/windows-amd64/newt.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-i586/gluegen-rt.dll b/ardor3d-jogl/lib/jogl/native/windows-i586/gluegen-rt.dll index 409fd66..897efe7 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-i586/gluegen-rt.dll and b/ardor3d-jogl/lib/jogl/native/windows-i586/gluegen-rt.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-i586/jogl_desktop.dll b/ardor3d-jogl/lib/jogl/native/windows-i586/jogl_desktop.dll index 415602e..6476d60 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-i586/jogl_desktop.dll and b/ardor3d-jogl/lib/jogl/native/windows-i586/jogl_desktop.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_awt.dll b/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_awt.dll index d3868c7..85e04e6 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_awt.dll and b/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_awt.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_win32.dll b/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_win32.dll index a9c0174..a4ba377 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_win32.dll and b/ardor3d-jogl/lib/jogl/native/windows-i586/nativewindow_win32.dll differ diff --git a/ardor3d-jogl/lib/jogl/native/windows-i586/newt.dll b/ardor3d-jogl/lib/jogl/native/windows-i586/newt.dll index 46f5f8e..adf30e0 100644 Binary files a/ardor3d-jogl/lib/jogl/native/windows-i586/newt.dll and b/ardor3d-jogl/lib/jogl/native/windows-i586/newt.dll differ diff --git a/ardor3d-jogl/src/main/java/com/ardor3d/input/jogl/JoglNewtMouseWrapper.java b/ardor3d-jogl/src/main/java/com/ardor3d/input/jogl/JoglNewtMouseWrapper.java index 6ecf6bb..182e769 100644 --- a/ardor3d-jogl/src/main/java/com/ardor3d/input/jogl/JoglNewtMouseWrapper.java +++ b/ardor3d-jogl/src/main/java/com/ardor3d/input/jogl/JoglNewtMouseWrapper.java @@ -10,9 +10,12 @@ package com.ardor3d.input.jogl; +import static com.google.common.base.Preconditions.checkNotNull; + import java.util.EnumMap; import java.util.EnumSet; import java.util.LinkedList; + import com.ardor3d.annotation.GuardedBy; import com.ardor3d.framework.jogl.NewtWindowContainer; import com.ardor3d.input.ButtonState; @@ -32,9 +35,6 @@ import com.jogamp.newt.event.MouseEvent; import com.jogamp.newt.event.MouseListener; import com.jogamp.newt.opengl.GLWindow; -import static com.google.common.base.Preconditions.checkNotNull; - - public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { @GuardedBy("this") @@ -47,11 +47,11 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { protected MouseState _lastState = null; protected final GLWindow _newtWindow; - + protected final MouseManager _manager; - + protected boolean _consumeEvents = false; - + protected final Multiset _clicks = EnumMultiset.create(MouseButton.class); protected final EnumMap _lastClickTime = Maps.newEnumMap(MouseButton.class); protected final EnumSet _clickArmed = EnumSet.noneOf(MouseButton.class); @@ -82,7 +82,7 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { return _currentIterator; } - + private void expireClickEvents() { if (!_clicks.isEmpty()) { for (final MouseButton mb : MouseButton.values()) { @@ -92,9 +92,9 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { } } } - + @Override - public synchronized void mousePressed(MouseEvent me) { + public synchronized void mousePressed(final MouseEvent me) { final MouseButton b = getButtonForEvent(me); if (_clickArmed.contains(b)) { _clicks.setCount(b, 0); @@ -115,7 +115,7 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { } @Override - public synchronized void mouseReleased(MouseEvent me) { + public synchronized void mouseReleased(final MouseEvent me) { initState(me); if (_consumeEvents) { me.setAttachment(InputEvent.consumedTag); @@ -137,14 +137,14 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { addNewState(me, buttons, null); } - + @Override - public synchronized void mouseDragged(MouseEvent me) { - mouseMoved(me); + public synchronized void mouseDragged(final MouseEvent me) { + mouseMoved(me); } - + @Override - public synchronized void mouseMoved(MouseEvent me) { + public synchronized void mouseMoved(final MouseEvent me) { _clickArmed.clear(); _clicks.clear(); @@ -159,7 +159,7 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { // check the state against the "ignore next" values if (_ignoreX != Integer.MAX_VALUE // shortcut to prevent dx/dy calculations - && (_ignoreX == getDX(me) && _ignoreY == getDY(me))) { + && (_ignoreX == getDX(me) && _ignoreY == getDY(me))) { // we matched, so we'll consider this a "mouse pointer reset move" // so reset ignore to let the next move event through. @@ -197,11 +197,11 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { _ignoreX = Integer.MAX_VALUE; _ignoreY = Integer.MAX_VALUE; } - } + } } @Override - public void mouseWheelMoved(MouseEvent me) { + public void mouseWheelMoved(final MouseEvent me) { initState(me); addNewState(me, _lastState.getButtonStates(), null); @@ -209,24 +209,24 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { me.setAttachment(InputEvent.consumedTag); } } - + private void initState(final MouseEvent mouseEvent) { if (_lastState == null) { _lastState = new MouseState(mouseEvent.getX(), getArdor3DY(mouseEvent), 0, 0, 0, null, null); } } - + private void addNewState(final MouseEvent mouseEvent, final EnumMap enumMap, final Multiset clicks) { final MouseState newState = new MouseState(mouseEvent.getX(), getArdor3DY(mouseEvent), getDX(mouseEvent), - getDY(mouseEvent), mouseEvent.getWheelRotation(), enumMap, clicks); + getDY(mouseEvent), (int) mouseEvent.getWheelRotation(), enumMap, clicks); synchronized (JoglNewtMouseWrapper.this) { _upcomingEvents.add(newState); } _lastState = newState; - } - + } + private int getDX(final MouseEvent me) { return me.getX() - _lastState.getX(); } @@ -234,7 +234,7 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { private int getDY(final MouseEvent me) { return getArdor3DY(me) - _lastState.getY(); } - + /** * @param e * our mouseEvent @@ -244,16 +244,16 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { private int getArdor3DY(final MouseEvent me) { return _newtWindow.getHeight() - me.getY(); } - + private void setStateForButton(final MouseEvent e, final EnumMap buttons, final ButtonState buttonState) { final MouseButton button = getButtonForEvent(e); buttons.put(button, buttonState); } - + private MouseButton getButtonForEvent(final MouseEvent me) { MouseButton button; - switch(me.getButton()) { + switch (me.getButton()) { case MouseEvent.BUTTON1: button = MouseButton.LEFT; break; @@ -268,9 +268,9 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { } return button; } - + private class JoglNewtMouseIterator extends AbstractIterator implements PeekingIterator { - + @Override protected MouseState computeNext() { synchronized (JoglNewtMouseWrapper.this) { @@ -281,25 +281,25 @@ public class JoglNewtMouseWrapper implements MouseWrapper, MouseListener { } } } - + @Override - public synchronized void mouseClicked(MouseEvent me) { + public synchronized void mouseClicked(final MouseEvent me) { // Yes, we could use the click count here, but in the interests of this working the same way as SWT and Native, // we // will do it the same way they do it. - + } @Override - public synchronized void mouseEntered(MouseEvent me) { - // ignore this + public synchronized void mouseEntered(final MouseEvent me) { + // ignore this } @Override - public synchronized void mouseExited(MouseEvent me) { - // ignore this - } - + public synchronized void mouseExited(final MouseEvent me) { + // ignore this + } + public boolean isConsumeEvents() { return _consumeEvents; } -- cgit v1.2.3