62 tuneGrid.addRow(0, oneLabel, oneDT);
63 tuneGrid.addRow(1, anotherLabel, anotherDT);
64 tuneGrid.addRow(2, parentLabel, parentDT);
65
66 oneNodeCmb.getSelectionModel().select(Nodes.RECTANGLE);
67 oneNodeCmb.setOnAction(new NodeChangeHandler(depthTestGroup.getChildren(), 0));
68 anotherNodeCmb.getSelectionModel().select(Nodes.CIRCLE);
69 anotherNodeCmb.setOnAction(new NodeChangeHandler(depthTestGroup.getChildren(), 1));
70
71 HBox nodeSwitches = new HBox(1);
72 nodeSwitches.getChildren().addAll(oneNodeCmb, anotherNodeCmb);
73
74 oneToFront.setOnAction(new FrontBackChangeHandler(depthTestGroup.getChildren(), 0));
75 anotherToFront.setOnAction(new FrontBackChangeHandler(depthTestGroup.getChildren(), 1));
76
77 VBox backFrontRadio = new VBox(1);
78 backFrontRadio.getChildren().addAll(oneToFront, anotherToFront);
79
80 VBox switchesAndRadios = new VBox(1);
81 switchesAndRadios.getChildren().addAll(tuneGrid, backFrontRadio,
82 HBoxBuilder.create().children(indicator, referenceGreen, referenceRed).spacing(10).
83 build(), details);
84
85 root.setLeft(depthTestGroup);
86 root.setRight(switchesAndRadios);
87 root.setTop(nodeSwitches);
88 setCamera(new PerspectiveCamera());
89
90 oneDT.setValue(DepthTest.INHERIT);
91 anotherDT.setValue(DepthTest.INHERIT);
92 parentDT.setValue(DepthTest.DISABLE);
93 }
94
95 private Label oneLabel = new Label("First node DepthTest");
96 private Label anotherLabel = new Label("Second node DepthTest");
97 private Label parentLabel = new Label("Parent node DepthTest");
98
99 private ObservableList<DepthTest> depthTestList = FXCollections.observableArrayList(DepthTest.values());
100 private ComboBox<DepthTest> oneDT = new ComboBox<DepthTest>(depthTestList);
101 private ComboBox<DepthTest> anotherDT = new ComboBox<DepthTest>(depthTestList);
102 private ComboBox<DepthTest> parentDT = new ComboBox<DepthTest>(
103 FXCollections.observableArrayList(DepthTest.DISABLE, DepthTest.ENABLE));
|
62 tuneGrid.addRow(0, oneLabel, oneDT);
63 tuneGrid.addRow(1, anotherLabel, anotherDT);
64 tuneGrid.addRow(2, parentLabel, parentDT);
65
66 oneNodeCmb.getSelectionModel().select(Nodes.RECTANGLE);
67 oneNodeCmb.setOnAction(new NodeChangeHandler(depthTestGroup.getChildren(), 0));
68 anotherNodeCmb.getSelectionModel().select(Nodes.CIRCLE);
69 anotherNodeCmb.setOnAction(new NodeChangeHandler(depthTestGroup.getChildren(), 1));
70
71 HBox nodeSwitches = new HBox(1);
72 nodeSwitches.getChildren().addAll(oneNodeCmb, anotherNodeCmb);
73
74 oneToFront.setOnAction(new FrontBackChangeHandler(depthTestGroup.getChildren(), 0));
75 anotherToFront.setOnAction(new FrontBackChangeHandler(depthTestGroup.getChildren(), 1));
76
77 VBox backFrontRadio = new VBox(1);
78 backFrontRadio.getChildren().addAll(oneToFront, anotherToFront);
79
80 VBox switchesAndRadios = new VBox(1);
81 switchesAndRadios.getChildren().addAll(tuneGrid, backFrontRadio,
82 new HBox(10, indicator, referenceGreen, referenceRed), details);
83
84 root.setLeft(depthTestGroup);
85 root.setRight(switchesAndRadios);
86 root.setTop(nodeSwitches);
87 setCamera(new PerspectiveCamera());
88
89 oneDT.setValue(DepthTest.INHERIT);
90 anotherDT.setValue(DepthTest.INHERIT);
91 parentDT.setValue(DepthTest.DISABLE);
92 }
93
94 private Label oneLabel = new Label("First node DepthTest");
95 private Label anotherLabel = new Label("Second node DepthTest");
96 private Label parentLabel = new Label("Parent node DepthTest");
97
98 private ObservableList<DepthTest> depthTestList = FXCollections.observableArrayList(DepthTest.values());
99 private ComboBox<DepthTest> oneDT = new ComboBox<DepthTest>(depthTestList);
100 private ComboBox<DepthTest> anotherDT = new ComboBox<DepthTest>(depthTestList);
101 private ComboBox<DepthTest> parentDT = new ComboBox<DepthTest>(
102 FXCollections.observableArrayList(DepthTest.DISABLE, DepthTest.ENABLE));
|