Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8127674

ScrollEvent on Mac seems broken in the controls scrum as of b317.

    XMLWordPrintable

Details

    Description


      The following testcase will work with Controls scrum b316, but fail with b317.

      On a Mac, simply place the cursor over the black rectangle, and
      use the tracker pad to send a ScrollEvent (two-findered drag).
      With b316 you will see the printlns from the handle(), with b317
      you won't.

      B316 & B317 can be found at :
        http://jfx.us.oracle.com/hudson/view/2.1/job/2.1-controls-scrum/316/
        http://jfx.us.oracle.com/hudson/view/2.1/job/2.1-controls-scrum/317/

      ------------------------------------------------------------------
      package simplescroll;

      import javafx.application.Application;
      import javafx.scene.Group;
      import javafx.scene.Node;
      import javafx.scene.Scene;
      import javafx.scene.shape.Rectangle;
      import javafx.stage.Stage;
      import javafx.event.EventHandler;
      import javafx.scene.input.ScrollEvent;


      public class Main extends Application {


          public static void main(String[] args) {
              Application.launch(args);
          }

          @Override public void start(Stage stage) {

              Scene scene = new Scene(new Group(), 600, 450);

              Group root = (Group)scene.getRoot();

              Rectangle r1 = new Rectangle(100, 100);
              r1.setOnScroll(new EventHandler<javafx.scene.input.ScrollEvent>() {
                      
                  @Override public void handle(ScrollEvent event) {
                     System.out.println("<><> we got a ScrollEvent : "+event);
                  }
              });
                 
              root.getChildren().add(r1);

              stage.setScene(scene);
              stage.show();
          }
      }
      ------------------------------------------------------------------

      Attachments

        Issue Links

          Activity

            People

              psafrata Pavel Ĺ afrata
              miflemi Mick Fleming
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:
                Imported: