-
Bug
-
Resolution: Fixed
-
P4
-
fx2.0
-
java6
fx b42
windows 7
To reproduce run following code and scroll mouse wheel on vertical scrollbar
import javafx.application.Application;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.scene.control.ScrollPane;
import javafx.scene.layout.HBox;
import javafx.scene.layout.VBox;
import javafx.scene.shape.Rectangle;
import javafx.stage.Stage;
public class ScrollPaneSampleRectangle extends Application {
public static void main(String[] args) {
launch( args);
}
private Parent getContent() {
VBox box = new VBox();
ScrollPane pane = new ScrollPane();
HBox hbox = new HBox(20);
hbox.getChildren().add(new Rectangle(10,10));
pane.setContent(hbox);
pane.setStyle("-fx-vbar-policy: always;");
pane.setFocusTraversable(false);
pane.setMaxSize(100, 100);
box.getChildren().add(pane);
return box;
}
public void start(Stage stage) {
stage.setX(100);
stage.setY(100);
stage.setWidth(300);
stage.setHeight(300);
Scene scene = new Scene(getContent());
stage.setScene(scene);
stage.show();
}
}
import javafx.application.Application;
import javafx.scene.Parent;
import javafx.scene.Scene;
import javafx.scene.control.ScrollPane;
import javafx.scene.layout.HBox;
import javafx.scene.layout.VBox;
import javafx.scene.shape.Rectangle;
import javafx.stage.Stage;
public class ScrollPaneSampleRectangle extends Application {
public static void main(String[] args) {
launch( args);
}
private Parent getContent() {
VBox box = new VBox();
ScrollPane pane = new ScrollPane();
HBox hbox = new HBox(20);
hbox.getChildren().add(new Rectangle(10,10));
pane.setContent(hbox);
pane.setStyle("-fx-vbar-policy: always;");
pane.setFocusTraversable(false);
pane.setMaxSize(100, 100);
box.getChildren().add(pane);
return box;
}
public void start(Stage stage) {
stage.setX(100);
stage.setY(100);
stage.setWidth(300);
stage.setHeight(300);
Scene scene = new Scene(getContent());
stage.setScene(scene);
stage.show();
}
}