When creating a SplitPane with the builder and setting up dividers it throws an java.lang.RuntimeException
code:
SplitPane.Divider divider = new SplitPane.Divider();
divider.setPosition(.4);
splitPane = new SplitPaneBuilder()
.items(box1, box2)
.dividers(divider)
.build();
Exception in Application start method
Exception in thread "main" java.lang.RuntimeException: Exception in Application start method
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:168)
at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:17)
at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:55)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.UnsupportedOperationException
at javafx.collections.FXCollections$UnmodifiableObservableListImpl.setAll(FXCollections.java:620)
at javafx.builders.SplitPaneAbstractBuilder.applyTo(SplitPaneAbstractBuilder.java:16)
at javafx.builders.SplitPaneAbstractBuilder.build(SplitPaneAbstractBuilder.java:83)
at javafxsamples.SplitPaneTest.init1(SplitPaneTest.java:29)
at javafxsamples.SplitPaneTest.start(SplitPaneTest.java:43)
at com.sun.javafx.application.LauncherImpl$3.run(LauncherImpl.java:127)
at com.sun.javafx.application.PlatformImpl$3.run(PlatformImpl.java:87)
at com.sun.javafx.application.PlatformImpl$2.run(PlatformImpl.java:65)
at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at com.sun.glass.ui.win.WinApplication.access$100(WinApplication.java:29)
at com.sun.glass.ui.win.WinApplication$1$1.run(WinApplication.java:49)
... 1 more
code:
SplitPane.Divider divider = new SplitPane.Divider();
divider.setPosition(.4);
splitPane = new SplitPaneBuilder()
.items(box1, box2)
.dividers(divider)
.build();
Exception in Application start method
Exception in thread "main" java.lang.RuntimeException: Exception in Application start method
at com.sun.javafx.application.LauncherImpl.launchApplication1(LauncherImpl.java:168)
at com.sun.javafx.application.LauncherImpl.access$000(LauncherImpl.java:17)
at com.sun.javafx.application.LauncherImpl$1.run(LauncherImpl.java:55)
at java.lang.Thread.run(Thread.java:662)
Caused by: java.lang.UnsupportedOperationException
at javafx.collections.FXCollections$UnmodifiableObservableListImpl.setAll(FXCollections.java:620)
at javafx.builders.SplitPaneAbstractBuilder.applyTo(SplitPaneAbstractBuilder.java:16)
at javafx.builders.SplitPaneAbstractBuilder.build(SplitPaneAbstractBuilder.java:83)
at javafxsamples.SplitPaneTest.init1(SplitPaneTest.java:29)
at javafxsamples.SplitPaneTest.start(SplitPaneTest.java:43)
at com.sun.javafx.application.LauncherImpl$3.run(LauncherImpl.java:127)
at com.sun.javafx.application.PlatformImpl$3.run(PlatformImpl.java:87)
at com.sun.javafx.application.PlatformImpl$2.run(PlatformImpl.java:65)
at com.sun.glass.ui.win.WinApplication._runLoop(Native Method)
at com.sun.glass.ui.win.WinApplication.access$100(WinApplication.java:29)
at com.sun.glass.ui.win.WinApplication$1$1.run(WinApplication.java:49)
... 1 more