Total deltas for scroll events from mouse wheel are wrong

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: P4
    • tbd
    • Affects Version/s: jfx14
    • Component/s: javafx
    • None
    • Environment:

      MacBook Pro Retina
      java.runtime.version: 14-ea+30-1385
      javafx.runtime.version: 14-ea+7

      but I have seen this on Windows too.

      When scroll events are generated via the mouse wheel, the total delta values returned by the event object are not correct.
      The documentation says: "The totalDeltaX and totalDeltaY contain the cumulative values for the whole gesture, zeros for mouse wheel". As you can see in the output of the test program below, the total-deltas for y are not zeros. The values are: e.getDeltaX(), e.getTotalDeltaX(), e.getDeltaY(), e.getTotalDeltaY(), e.getTouchCount()

      setOnScroll: 0,000000 0,000000 1,000061 1,000061 0
      setOnScroll: 0,000000 0,000000 1,000061 1,000061 0
      setOnScroll: 0,000000 0,000000 1,000061 1,000061 0
      setOnScroll: 0,000000 0,000000 1,000061 1,000061 0
      setOnScroll: 0,000000 0,000000 4,296417 4,296417 0
      setOnScroll: 0,000000 0,000000 -1,000061 -1,000061 0
      setOnScroll: 0,000000 0,000000 -11,195526 -11,195526 0
      setOnScroll: 0,000000 0,000000 -38,627014 -38,627014 0
      setOnScroll: 0,000000 0,000000 -50,805664 -50,805664 0
      setOnScroll: 0,000000 0,000000 -52,142639 -52,142639 0

      This was originally reported in the context of https://bugs.openjdk.java.net/browse/JDK-8236971

            Assignee:
            Kevin Rushforth
            Reporter:
            Michael Paus
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: