Mantis Bug Tracker

View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0000315OLVUser Interfacepublic2011-10-18 14:412012-07-26 16:00
ReporterBenFenner 
Assigned ToBenFenner 
PrioritynormalSeverityfeatureReproducibilityN/A
StatusassignedResolutionopen 
PlatformAllOSAllOS VersionAll
Product Version0.0.1-SNAPSHOT 
Target VersionFutureFixed in Version 
Summary0000315: Get horizontal scrolling to scroll the graph left and right.
DescriptionGet horizontal scrolling (laptops with horizontal scroll on touch pad and certain mouses) to scroll the graph left and right.
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
User avatar (0001118)
BenFenner (developer)
2012-01-13 19:58

Ended up buying this piece of crap to see if I can develop this feature. I almost bought a decent mouse, but didn't feel like shelling out around $50-$75 just for this one thing.

http://www.newegg.com/Product/Product.aspx?Item=N82E16826104343 [^]

I'm still not even sure Java Swing fires these events, as I can't find reference to them anywhere.
User avatar (0001142)
BenFenner (developer)
2012-01-19 17:40
edited on: 2012-01-19 18:11

I have the tilt wheel mouse working (requires obnoxious, bloated Logitech input suit to even work) and it scrolls horizontally in Firefox and Eclipse as tests.

I can't find the event(s) it dispatches however, even using an AWTEventListener with this code snippet:

Toolkit toolkit = this.getToolkit();
long mymodifier =
  AWTEvent.ACTION_EVENT_MASK |
  AWTEvent.ADJUSTMENT_EVENT_MASK |
  AWTEvent.COMPONENT_EVENT_MASK |
  AWTEvent.CONTAINER_EVENT_MASK |
  AWTEvent.FOCUS_EVENT_MASK |
  AWTEvent.HIERARCHY_BOUNDS_EVENT_MASK |
  AWTEvent.HIERARCHY_EVENT_MASK |
  AWTEvent.INPUT_METHOD_EVENT_MASK |
  AWTEvent.INVOCATION_EVENT_MASK |
  AWTEvent.ITEM_EVENT_MASK |
  AWTEvent.KEY_EVENT_MASK |
  AWTEvent.MOUSE_EVENT_MASK |
  AWTEvent.MOUSE_MOTION_EVENT_MASK |
  AWTEvent.MOUSE_WHEEL_EVENT_MASK |
  AWTEvent.PAINT_EVENT_MASK |
  AWTEvent.TEXT_EVENT_MASK |
  AWTEvent.WINDOW_EVENT_MASK |
  AWTEvent.WINDOW_FOCUS_EVENT_MASK |
  AWTEvent.WINDOW_STATE_EVENT_MASK;
toolkit.addAWTEventListener(this, mymodifier);



I've found feature requests dating from around 2002 all the way up to 2010 asking for this feature to be implemented in Java. Here are a few links:

http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6315717 [^]
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6440198 [^]


The current way of doing this, since it seems it is still unsupported, is by using the Java Native Interface to work with the OS directly. This is something that would be more work than it is worth in my opinion. I'm going to solicit confirmation from Fred to make sure his devices also don't dispatch these events. If that is the case, we'll close the issue for now. If Java ever gets the capability we should revisit this.

User avatar (0001143)
BenFenner (developer)
2012-01-19 18:13
edited on: 2012-01-19 18:16

Upon closer inspection, the code above seems to capture middle clicks just fine when using a normal setup, but when I turn on the Logitech suite to gain tilt wheel functionality then even the middle clicks don't dispatch an event. Clearly this setup is not ideal and more testing is in order.

User avatar (0001144)
Fred (administrator)
2012-01-20 14:24

Consider using the value of long that is all ones as your mask, too.
User avatar (0001146)
BenFenner (developer)
2012-01-20 20:08

Mac trackpad debug info:

Scroll down:

--------------------------
Event ID : 507
Event String: java.awt.event.MouseWheelEvent[MOUSE_WHEEL,(491,188),absolute(0,0),button=0,clickCount=0,scrollType=WHEEL_UNIT_SCROLL,scrollAmount=1,wheelRotation=4] on Graphing Panel
-----------
Button : 0
Click Count: 0
Modifiers : 0
ModifiersEx: 0
Scrl Amount: 1
Scrl Type : 0
UntsToScrl : 4
Whl Rot : 4
When : 1327089445759
X : 491
X on Scrn : 0
Y : 188
Y on Scrn : 0
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false



Scroll up:

--------------------------
Event ID : 507
Event String: java.awt.event.MouseWheelEvent[MOUSE_WHEEL,(413,169),absolute(0,0),button=0,clickCount=0,scrollType=WHEEL_UNIT_SCROLL,scrollAmount=1,wheelRotation=-2] on frame0
-----------
Button : 0
Click Count: 0
Modifiers : 0
ModifiersEx: 0
Scrl Amount: 1
Scrl Type : 0
UntsToScrl : -2
Whl Rot : -2
When : 1327089533230
X : 413
X on Scrn : 0
Y : 169
Y on Scrn : 0
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false



Scroll left:

--------------------------
Event ID : 507
Event String: java.awt.event.MouseWheelEvent[MOUSE_WHEEL,(373,232),absolute(0,0),button=0,modifiers=?,extModifiers=?,clickCount=0,scrollType=WHEEL_UNIT_SCROLL,scrollAmount=1,wheelRotation=-2] on Graphing Panel
-----------
Button : 0
Click Count: 0
Modifiers : 1
ModifiersEx: 64
Scrl Amount: 1
Scrl Type : 0
UntsToScrl : -1
Whl Rot : -1
When : 1327089907269
X : 373
X on Scrn : 0
Y : 232
Y on Scrn : 0
Alt? : false
Ctrl? : false
Shift? : true
Meta? : false





Scroll right:

--------------------------
Event ID : 507
Event String: java.awt.event.MouseWheelEvent[MOUSE_WHEEL,(413,263),absolute(0,0),button=0,modifiers=?,extModifiers=?,clickCount=0,scrollType=WHEEL_UNIT_SCROLL,scrollAmount=1,wheelRotation=1] on Graphing Panel
-----------
Button : 0
Click Count: 0
Modifiers : 1
ModifiersEx: 64
Scrl Amount: 1
Scrl Type : 0
UntsToScrl : 1
Whl Rot : 1
When : 1327089830639
X : 413
X on Scrn : 0
Y : 263
Y on Scrn : 0
Alt? : false
Ctrl? : false
Shift? : true
Meta? : false
User avatar (0001147)
BenFenner (developer)
2012-01-20 21:49
edited on: 2012-01-20 22:05

Linux with Logitech M305 tilt-wheel debug info:

Scroll down:

--------------------------
Event ID : 507
Event String: java.awt.event.MouseWheelEvent[MOUSE_WHEEL,(420,194),absolute(420,194),button=0,clickCount=1,scrollType=WHEEL_UNIT_SCROLL,scrollAmount=3,wheelRotation=1] on frame0
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
Scrl Amount: 3
Scrl Type : 0
UntsToScrl : 3
Whl Rot : 1
When : 1327095862120
X : 420
X on Scrn : 420
Y : 194
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false





Scroll up:

--------------------------
Event ID : 507
Event String: java.awt.event.MouseWheelEvent[MOUSE_WHEEL,(419,151),absolute(420,194),button=0,clickCount=1,scrollType=WHEEL_UNIT_SCROLL,scrollAmount=3,wheelRotation=-1] on Graphing Panel
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
Scrl Amount: 3
Scrl Type : 0
UntsToScrl : -3
Whl Rot : -1
When : 1327095863488
X : 419
X on Scrn : 420
Y : 151
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false





Scroll left:

--------------------------
Event ID : 501
Event String: java.awt.event.MouseEvent[MOUSE_PRESSED,(419,151),absolute(420,194),button=0,clickCount=1] on Graphing Panel
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
When : 1327095864778
X : 419
X on Scrn : 420
Y : 151
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false
--------------------------
Event ID : 502
Event String: java.awt.event.MouseEvent[MOUSE_RELEASED,(419,151),absolute(420,194),button=0,clickCount=1] on Graphing Panel
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
When : 1327095864778
X : 419
X on Scrn : 420
Y : 151
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false
--------------------------
Event ID : 500
Event String: java.awt.event.MouseEvent[MOUSE_CLICKED,(419,151),absolute(420,194),button=0,clickCount=1] on Graphing Panel
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
When : 1327095864778
X : 419
X on Scrn : 420
Y : 151
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false





Scroll right:

--------------------------
Event ID : 501
Event String: java.awt.event.MouseEvent[MOUSE_PRESSED,(419,151),absolute(420,194),button=0,clickCount=1] on Graphing Panel
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
When : 1327095866410
X : 419
X on Scrn : 420
Y : 151
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false
--------------------------
Event ID : 502
Event String: java.awt.event.MouseEvent[MOUSE_RELEASED,(419,151),absolute(420,194),button=0,clickCount=1] on Graphing Panel
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
When : 1327095866410
X : 419
X on Scrn : 420
Y : 151
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false
--------------------------
Event ID : 500
Event String: java.awt.event.MouseEvent[MOUSE_CLICKED,(419,151),absolute(420,194),button=0,clickCount=1] on Graphing Panel
-----------
Button : 0
Click Count: 1
Modifiers : 0
ModifiersEx: 0
When : 1327095866410
X : 419
X on Scrn : 420
Y : 151
Y on Scrn : 194
Alt? : false
Ctrl? : false
Shift? : false
Meta? : false

User avatar (0001736)
BenFenner (developer)
2012-07-26 16:00

This issue really needs to wait until Java has native horizontal scroll wheel support. Or at least until I get a development environment working to test this on Windows 7. That may happen soon, but this issue is getting moved from release 0.0.3 to "Future".


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker