RFR: 6911375: mouseWheel has no effect without vertical scrollbar

Prasanta Sadhukhan psadhukhan at openjdk.java.net
Wed Feb 23 04:33:23 UTC 2022


It is observed that mouseWheel doesn't scroll through a list if there is no scrollbar even though pressing PageUp/Down using keyboard moves up/down the list.
Issue stems from the fact that BasicScrollPaneUI.Handler.mouseWheelMoved() skips the mouse wheel events when the scrollbar is not visible. 
Fixed to handle mouseWheelEvent even though scrollbar is not visible with the assumption that if both vertical and horizontal scrollbar is not visible, then assume default orientation to be vertical.

Existing jtreg, jck tests are ok. All L&F works well with the fix and testcase works in all platforms except on mac which will be handled separately.

-------------

Commit messages:
 - 6911375: mouseWheel has no effect without vertical scrollbar
 - 6911375: mouseWheel has no effect without vertical scrollbar

Changes: https://git.openjdk.java.net/jdk/pull/7585/files
 Webrev: https://webrevs.openjdk.java.net/?repo=jdk&pr=7585&range=00
  Issue: https://bugs.openjdk.java.net/browse/JDK-6911375
  Stats: 132 lines in 2 files changed: 129 ins; 1 del; 2 mod
  Patch: https://git.openjdk.java.net/jdk/pull/7585.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/7585/head:pull/7585

PR: https://git.openjdk.java.net/jdk/pull/7585



More information about the client-libs-dev mailing list