Normand Briere
2019-05-01 20c1a07b76c39462594aedfedfe6e6adb17cd552
ObjEditor.java
....@@ -138,34 +138,40 @@
138138 public void closeUI()
139139 {
140140 //new Exception().printStackTrace();
141
- System.out.println("this = " + this);
142
- System.out.println("objEditor = " + objEditor);
141
+// System.out.println("this = " + this);
142
+// System.out.println("objEditor = " + objEditor);
143143 //nameField.removeActionListener(this);
144
- objEditor.ctrlPanel.remove(nameField);
144
+// objEditor.ctrlPanel.remove(nameField);
145145
146146 if (!GroupEditor.allparams)
147147 return;
148148
149
- objEditor.ctrlPanel.remove(liveCB);
150
- objEditor.ctrlPanel.remove(hideCB);
151
- objEditor.ctrlPanel.remove(markCB);
152
-
153
- objEditor.ctrlPanel.remove(randomCB);
154
- objEditor.ctrlPanel.remove(speedupCB);
155
- objEditor.ctrlPanel.remove(rewindCB);
156
-
157
- objEditor.ctrlPanel.remove(resetButton);
158
- objEditor.ctrlPanel.remove(stepButton);
159
-// objEditor.ctrlPanel.remove(stepAllButton);
160
-// objEditor.ctrlPanel.remove(resetAllButton);
161
- objEditor.ctrlPanel.remove(link2masterCB);
162
- //objEditor.ctrlPanel.remove(flipVCB);
163
- //objEditor.ctrlPanel.remove(texresMenu);
164
- objEditor.ctrlPanel.remove(slowerButton);
165
- objEditor.ctrlPanel.remove(fasterButton);
166
- objEditor.ctrlPanel.remove(remarkButton);
149
+// objEditor.ctrlPanel.remove(liveCB);
150
+// objEditor.ctrlPanel.remove(hideCB);
151
+// objEditor.ctrlPanel.remove(markCB);
152
+//
153
+// objEditor.ctrlPanel.remove(randomCB);
154
+// objEditor.ctrlPanel.remove(speedupCB);
155
+// objEditor.ctrlPanel.remove(rewindCB);
156
+//
157
+// objEditor.ctrlPanel.remove(resetButton);
158
+// objEditor.ctrlPanel.remove(stepButton);
159
+//// objEditor.ctrlPanel.remove(stepAllButton);
160
+//// objEditor.ctrlPanel.remove(resetAllButton);
161
+// objEditor.ctrlPanel.remove(link2masterCB);
162
+// //objEditor.ctrlPanel.remove(flipVCB);
163
+// //objEditor.ctrlPanel.remove(texresMenu);
164
+// objEditor.ctrlPanel.remove(slowerButton);
165
+// objEditor.ctrlPanel.remove(fasterButton);
166
+// objEditor.ctrlPanel.remove(remarkButton);
167167
168
- Remove(normalpushField);
168
+ objEditor.ctrlPanel.remove(namePanel);
169
+ objEditor.ctrlPanel.remove(setupPanel);
170
+ objEditor.ctrlPanel.remove(commandsPanel);
171
+ objEditor.ctrlPanel.remove(pushPanel);
172
+ //objEditor.ctrlPanel.remove(fillPanel);
173
+
174
+ //Remove(normalpushField);
169175 }
170176
171177 public ObjEditor GetEditor()
....@@ -353,21 +359,23 @@
353359 objectPanel = new JTabbedPane();
354360 toolbarPanel = new JPanel();
355361 toolbarPanel.setName("Toolbar");
356
- treePanel = new JPanel();
362
+ treePanel = new cGridBag();
357363 treePanel.setName("Tree");
358
- ctrlPanel = new cGridBag(); // new GridBagLayout());
364
+ ctrlPanel = new cGridBag().setVertical(false); // new GridBagLayout());
359365 ctrlPanel.setName("Edit");
360366 materialPanel = new cGridBag().setVertical(true);
361367 materialPanel.setName("Material");
362368 /*JTextPane*/
363369 infoarea = createTextPane();
370
+ doc = infoarea.getStyledDocument();
371
+
364372 infoarea.setEditable(true);
365373 SetText();
366374 // infoarea.setFont(infoarea.getFont().deriveFont(10, 14f));
367375 // infoarea.setOpaque(false);
368376 // //infoarea.setForeground(textcolor);
369
- infoarea.setLineWrap(true);
370
- infoarea.setWrapStyleWord(true);
377
+// TEXTAREA infoarea.setLineWrap(true);
378
+// TEXTAREA infoarea.setWrapStyleWord(true);
371379 infoPanel = new JScrollPane(infoarea, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); //AS_NEEDED);
372380 infoPanel.setPreferredSize(new Dimension(50, 200));
373381 infoPanel.setName("Info");
....@@ -378,15 +386,15 @@
378386 mainPanel.setName("Main");
379387 mainPanel.setContinuousLayout(true);
380388 mainPanel.setOneTouchExpandable(true);
381
- mainPanel.setDividerLocation(1.0);
382389 mainPanel.setDividerSize(9);
383
- mainPanel.setResizeWeight(0);
390
+ mainPanel.setDividerLocation(0.5); //1.0);
391
+ mainPanel.setResizeWeight(0.5);
384392
385393 //ctrlPanel.setLayout(new GridLayout(4, 1, 5, 5));
386394 //mainPanel.setLayout(new GridBagLayout());
387395 toolbarPanel.setLayout(new FlowLayout(FlowLayout.LEFT));
388
- treePanel.setLayout(new GridBagLayout());
389
- ctrlPanel.setLayout(new GridBagLayout());
396
+// treePanel.setLayout(new GridBagLayout());
397
+ //ctrlPanel.setLayout(new GridBagLayout());
390398 //materialPanel.setLayout(new GridBagLayout());
391399
392400 aConstraints = new GridBagConstraints(0, 0, 1, 1, 1.0, 1.0,
....@@ -426,7 +434,7 @@
426434 static String newline = "\n";
427435 protected static final String buttonString = "JButton";
428436 StyledDocument doc;
429
- JTextArea infoarea;
437
+ JTextPane infoarea;
430438
431439 void ClearInfo()
432440 {
....@@ -493,7 +501,10 @@
493501 }
494502
495503 if (full)
496
- si.SendInfo(" BBox: " + minima + " - " + maxima, "regular");
504
+ {
505
+ si.SendInfo(" BBox min: " + minima, "regular");
506
+ si.SendInfo(" BBox max: " + maxima, "regular");
507
+ }
497508
498509 if (sel.bRep != null)
499510 {
....@@ -591,6 +602,9 @@
591602 {
592603 CameraPane.pointflow = (PointFlow) sel;
593604 }
605
+
606
+ si.SendInfo("_____________________", "regular");
607
+ si.SendInfo("", "regular");
594608 }
595609 }
596610
....@@ -622,52 +636,52 @@
622636 cameraView.ToggleFullScreen();
623637 }
624638
625
- private JTextArea createTextPane()
639
+ private JTextPane createTextPane()
626640 {
627
- String[] initString =
628
- {
629
- "This is an editable JTextPane, ", //regular
630
- "another ", //italic
631
- "styled ", //bold
632
- "text ", //small
633
- "component, ", //large
634
- "which supports embedded components..." + newline,//regular
635
- " " + newline, //button
636
- "...and embedded icons..." + newline, //regular
637
- " ", //icon
638
- newline + "JTextPane is a subclass of JEditorPane that "
639
- + "uses a StyledEditorKit and StyledDocument, and provides "
640
- + "cover methods for interacting with those objects."
641
- };
641
+// TEXTAREA String[] initString =
642
+// {
643
+// "This is an editable JTextPane, ", //regular
644
+// "another ", //italic
645
+// "styled ", //bold
646
+// "text ", //small
647
+// "component, ", //large
648
+// "which supports embedded components..." + newline,//regular
649
+// " " + newline, //button
650
+// "...and embedded icons..." + newline, //regular
651
+// " ", //icon
652
+// newline + "JTextPane is a subclass of JEditorPane that "
653
+// + "uses a StyledEditorKit and StyledDocument, and provides "
654
+// + "cover methods for interacting with those objects."
655
+// };
656
+//
657
+// String[] initStyles =
658
+// {
659
+// "regular", "italic", "bold", "small", "large",
660
+// "regular", "button", "regular", "icon",
661
+// "regular"
662
+// };
663
+//
664
+// JTextPane textPane = new JTextPane();
665
+// textPane.setEditable(true);
666
+// /*StyledDocument*/ doc = textPane.getStyledDocument();
667
+// addStylesToDocument(doc);
668
+//
669
+// try
670
+// {
671
+// for (int j = 0; j < 2; j++)
672
+// {
673
+// for (int i = 0; i < initString.length; i++)
674
+// {
675
+// doc.insertString(doc.getLength(), initString[i],
676
+// doc.getStyle(initStyles[i]));
677
+// }
678
+// }
679
+// } catch (BadLocationException ble)
680
+// {
681
+// System.err.println("Couldn't insert initial text into text pane.");
682
+// }
642683
643
- String[] initStyles =
644
- {
645
- "regular", "italic", "bold", "small", "large",
646
- "regular", "button", "regular", "icon",
647
- "regular"
648
- };
649
-
650
- JTextPane textPane = new JTextPane();
651
- textPane.setEditable(true);
652
- /*StyledDocument*/ doc = textPane.getStyledDocument();
653
- addStylesToDocument(doc);
654
-
655
- try
656
- {
657
- for (int j = 0; j < 2; j++)
658
- {
659
- for (int i = 0; i < initString.length; i++)
660
- {
661
- doc.insertString(doc.getLength(), initString[i],
662
- doc.getStyle(initStyles[i]));
663
- }
664
- }
665
- } catch (BadLocationException ble)
666
- {
667
- System.err.println("Couldn't insert initial text into text pane.");
668
- }
669
-
670
- return new JTextArea(); // textPane;
684
+ return new JTextPane(); // textPane;
671685 }
672686
673687 protected void addStylesToDocument(StyledDocument doc)
....@@ -767,54 +781,44 @@
767781 JButton slowerButton;
768782 JButton fasterButton;
769783 JButton remarkButton;
784
+
785
+ cGridBag namePanel;
786
+ cGridBag setupPanel;
787
+ cGridBag commandsPanel;
788
+ cGridBag pushPanel;
789
+ cGridBag fillPanel;
770790
771
- JCheckBox AddCheckBox(ObjEditor oe, String label, boolean on)
791
+ JCheckBox AddCheckBox(cGridBag panel, String label, boolean on)
772792 {
773793 JCheckBox cb;
774794
775
- oe.aConstraints.fill = GridBagConstraints.HORIZONTAL;
776
- oe.aConstraints.gridwidth = 1; // 3;
777
-// oe.aConstraints.weightx = 1;
778
-// oe.aConstraints.anchor = GridBagConstraints.WEST;
779
- oe.ctrlPanel.add(cb = new JCheckBox(label, on), oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
795
+ panel.add(cb = new JCheckBox(label, on)); //, oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
780796 cb.addItemListener(this);
781
-// oe.aConstraints.anchor = GridBagConstraints.EAST;
782
- oe.aConstraints.gridwidth = 1;
783
- oe.aConstraints.gridx += 1;
784797
785798 return cb;
786799 }
787800
788
- cButton AddButton(ObjEditor oe, String label)
801
+ cButton AddButton(cGridBag panel, String label)
789802 {
790803 cButton cb;
791804
792
- oe.aConstraints.fill = GridBagConstraints.HORIZONTAL;
793
- oe.aConstraints.gridwidth = 1;
794
-// oe.aConstraints.weightx = 1;
795
-// oe.aConstraints.anchor = GridBagConstraints.WEST;
796
- oe.ctrlPanel.add(cb = new cButton(label), oe.aConstraints, oe.ctrlPanel.getComponentCount() - 1);
805
+ panel.add(cb = new cButton(label)); //, oe.aConstraints, oe.ctrlPanel.getComponentCount() - 1);
797806 cb.addActionListener(this);
798
-// oe.aConstraints.anchor = GridBagConstraints.EAST;
799
- oe.aConstraints.gridwidth = 1;
800
- oe.aConstraints.gridx += 1;
801807
802808 return cb;
803809 }
804810
805
- JComboBox AddCombo(ObjEditor oe, java.util.Vector list, int item)
811
+ JComboBox AddCombo(cGridBag panel, java.util.Vector list, int item)
806812 {
807813 JComboBox combo;
808814
809
- oe.aConstraints.fill = GridBagConstraints.HORIZONTAL;
810
- oe.ctrlPanel.add(combo = new JComboBox(new cListModel(list, item)), oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
811
- oe.aConstraints.gridx += 1;
815
+ panel.add(combo = new JComboBox(new cListModel(list, item))); //, oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
812816 combo.addActionListener(this);
813817
814818 return combo;
815819 }
816820
817
- cNumberSlider AddSlider(cGridBag ctrlPanel, String label, double min, double max, double current, double pow)
821
+ cGridBag AddSlider(cGridBag panel, String label, double min, double max, double current, double pow)
818822 {
819823 cGridBag control = new cGridBag();
820824
....@@ -826,12 +830,12 @@
826830 control.add(combo = new cNumberSlider(this, min, max, pow)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
827831 combo.setFloat(current);
828832
829
- ctrlPanel.add(control);
833
+ panel.add(control);
830834
831
- return combo;
835
+ return control;
832836 }
833837
834
- cNumberSlider AddSlider(cGridBag ctrlPanel, String label, int min, int max, int current)
838
+ cGridBag AddSlider(cGridBag panel, String label, int min, int max, int current)
835839 {
836840 cGridBag control = new cGridBag();
837841
....@@ -839,25 +843,21 @@
839843
840844 JLabel jlabel = new JLabel(label);
841845 jlabel.setHorizontalAlignment(SwingConstants.TRAILING);
842
- ctrlPanel.add(jlabel); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
843
- ctrlPanel.add(combo = new cNumberSlider(this, min, max)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
846
+ control.add(jlabel); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
847
+ control.add(combo = new cNumberSlider(this, min, max)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
844848 combo.setInteger(current);
845849
846
- ctrlPanel.add(control);
850
+ panel.add(control);
847851
848
- return combo;
852
+ return control;
849853 }
850854
851855 JTextArea AddText(cGridBag ctrlPanel, String name)
852856 {
853857 JTextArea text;
854858
855
- aConstraints.fill = GridBagConstraints.HORIZONTAL;
856
- aConstraints.gridwidth = ObjEditor.GRIDWIDTH;
857859 ctrlPanel.add(text = new JTextArea(name)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1);
858860 text.addCaretListener(this);
859
- aConstraints.gridx += 1;
860
- aConstraints.gridwidth = 1;
861861
862862 return text;
863863 }
....@@ -896,7 +896,7 @@
896896
897897 /*
898898 */
899
- void Return() // ObjEditor oe)
899
+ void Return0() // ObjEditor oe)
900900 {
901901 aConstraints.gridy += 1;
902902 aConstraints.gridx = 0;
....@@ -955,33 +955,52 @@
955955 // oe.aConstraints.weighty = 0;
956956 // oe.aConstraints.gridx = 0;
957957 // oe.aConstraints.gridy = 0;
958
- SetupName(oe);
958
+ //SetupName(oe);
959
+
960
+ namePanel = new cGridBag();
961
+
962
+ nameField = AddText(namePanel, copy.GetName());
963
+ namePanel.add(nameField);
964
+ oe.ctrlPanel.add(namePanel);
965
+
966
+ oe.ctrlPanel.Return();
959967
960968 if (!GroupEditor.allparams)
961969 return;
962970
963
- liveCB = AddCheckBox(oe, "Live", copy.live);
964
- link2masterCB = AddCheckBox(oe, "Supp", copy.link2master);
965
- hideCB = AddCheckBox(oe, "Hide", copy.hide);
971
+ setupPanel = new cGridBag().setVertical(false);
972
+
973
+ liveCB = AddCheckBox(setupPanel, "Live", copy.live);
974
+ link2masterCB = AddCheckBox(setupPanel, "Supp", copy.link2master);
975
+ hideCB = AddCheckBox(setupPanel, "Hide", copy.hide);
966976 // Return();
967
- markCB = AddCheckBox(oe, "Mark", copy.marked);
968
- rewindCB = AddCheckBox(oe, "Rew", copy.rewind);
969
- randomCB = AddCheckBox(oe, "Rand", copy.random);
970
- Return();
971
- resetButton = AddButton(oe, "Reset");
972
- stepButton = AddButton(oe, "Step");
977
+ markCB = AddCheckBox(setupPanel, "Mark", copy.marked);
978
+ rewindCB = AddCheckBox(setupPanel, "Rew", copy.rewind);
979
+ randomCB = AddCheckBox(setupPanel, "Rand", copy.random);
980
+
981
+ oe.ctrlPanel.add(setupPanel);
982
+ oe.ctrlPanel.Return();
983
+
984
+ commandsPanel = new cGridBag().setVertical(false);
985
+
986
+ resetButton = AddButton(commandsPanel, "Reset");
987
+ stepButton = AddButton(commandsPanel, "Step");
973988 // resetAllButton = AddButton(oe, "Reset All");
974989 // stepAllButton = AddButton(oe, "Step All");
975
- speedupCB = AddCheckBox(oe, "Speed", copy.speedup);
990
+ speedupCB = AddCheckBox(commandsPanel, "Speed", copy.speedup);
976991 // Return();
977
- slowerButton = AddButton(oe, "Slow");
978
- fasterButton = AddButton(oe, "Fast");
979
- remarkButton = AddButton(oe, "Rem");
992
+ slowerButton = AddButton(commandsPanel, "Slow");
993
+ fasterButton = AddButton(commandsPanel, "Fast");
994
+ remarkButton = AddButton(commandsPanel, "Remark");
980995
981
- //Return();
996
+ oe.ctrlPanel.add(commandsPanel);
997
+ oe.ctrlPanel.Return();
982998
983
- //normalpushField = AddSlider(oe.ctrlPanel, "Push", -10, 10, 0, -1);
999
+ pushPanel = AddSlider(oe.ctrlPanel, "Push", -10, 10, 0, 1);
1000
+ normalpushField = (cNumberSlider)pushPanel.getComponent(1);
9841001 //Return();
1002
+
1003
+ oe.ctrlPanel.Return();
9851004
9861005 // oe.ctrlPanel.add(stepButton = new cButton("Step"), ObjEditor.aConstraints, oe.ctrlPanel.getComponentCount() - 2);
9871006 // ObjEditor.aConstraints.gridx += 1;
....@@ -1076,7 +1095,7 @@
10761095 oe.aConstraints.gridwidth = 1;
10771096 /**/
10781097 nameField = AddText(oe.ctrlPanel, copy.GetName());
1079
- Return();
1098
+ oe.ctrlPanel.Return();
10801099
10811100 //ctrlPanel.add(textureButton = new Button("Texture..."));
10821101 //textureButton.setEnabled(false);
....@@ -1253,10 +1272,11 @@
12531272 //JScrollPane tmp = new JScrollPane(ctrlPanel, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
12541273 //tmp.setName("Edit");
12551274 objectPanel.add(materialPanel);
1256
- JPanel north = new JPanel(new BorderLayout());
1257
- north.setName("Edit");
1258
- north.add(ctrlPanel, BorderLayout.NORTH);
1259
- objectPanel.add(north);
1275
+// JPanel north = new JPanel(new BorderLayout());
1276
+// north.setName("Edit");
1277
+// north.add(ctrlPanel, BorderLayout.NORTH);
1278
+// objectPanel.add(north);
1279
+ objectPanel.add(ctrlPanel);
12601280 objectPanel.add(infoPanel);
12611281
12621282 /*
....@@ -1415,7 +1435,7 @@
14151435 ctrlPanel.removeAll();
14161436 }
14171437
1418
- void SetupMaterial(cGridBag ctrlPanel)
1438
+ void SetupMaterial(cGridBag panel)
14191439 {
14201440 /*
14211441 ctrlPanel.add(materialLabel = new JLabel("MATERIAL : "), aConstraints);
....@@ -1424,18 +1444,23 @@
14241444
14251445 cGridBag editBar = new cGridBag().setVertical(false);
14261446
1427
- editBar.add(createMaterialButton = new cButton("Create")); // , aConstraints);
1447
+ editBar.add(createMaterialButton = new cButton("Create", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1448
+ createMaterialButton.setToolTipText("Create material");
14281449
14291450 /*
14301451 ctrlPanel.add(resetSlidersButton = new cButton("Reset All"), aConstraints);
14311452 */
14321453
1433
- editBar.add(clearMaterialButton = new cButton("Clear")); // , aConstraints);
1434
- editBar.add(resetSlidersButton = new cButton("Reset")); // , aConstraints);
1454
+ editBar.add(clearMaterialButton = new cButton("Clear", !GrafreeD.NIMBUSLAF)); // , aConstraints);
1455
+ clearMaterialButton.setToolTipText("Clear material");
1456
+
1457
+ editBar.add(resetSlidersButton = new cButton("Reset", !GrafreeD.NIMBUSLAF)); // , aConstraints);
14351458 editBar.add(propagateToggle = new cCheckBox("Prop", propagate)); // , aConstraints);
14361459 editBar.add(multiplyToggle = new cCheckBox("Mult", false)); // , aConstraints);
14371460
1438
- ctrlPanel.add(editBar);
1461
+ editBar.preferredHeight = 15;
1462
+
1463
+ panel.add(editBar);
14391464
14401465 /**/
14411466 //aConstraints.weighty = 0;
....@@ -1484,9 +1509,9 @@
14841509 shadowbias.add(shadowbiasField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
14851510 colorSection.add(shadowbias);
14861511
1487
- ctrlPanel.add(new JSeparator());
1512
+ panel.add(new JSeparator());
14881513
1489
- ctrlPanel.add(colorSection);
1514
+ panel.add(colorSection);
14901515
14911516 //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
14921517
....@@ -1534,9 +1559,9 @@
15341559 fakedepth.add(fakedepthField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
15351560 diffuseSection.add(fakedepth);
15361561
1537
- ctrlPanel.add(new JSeparator());
1562
+ panel.add(new JSeparator());
15381563
1539
- ctrlPanel.add(diffuseSection);
1564
+ panel.add(diffuseSection);
15401565
15411566 //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
15421567
....@@ -1572,7 +1597,7 @@
15721597 velvet.add(velvetField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints);
15731598 specularSection.add(velvet);
15741599
1575
- shiftField = AddSlider(specularSection, "Shift", 0.001, 50, copy.material.shift, -1);
1600
+ shiftField = (cNumberSlider)AddSlider(specularSection, "Shift", 0.001, 50, copy.material.shift, -1).getComponent(1);
15761601 //Return();
15771602 // ctrlPanel.add(shiftLabel = new JLabel("Shift"), aConstraints);
15781603 // shiftLabel.setHorizontalAlignment(SwingConstants.TRAILING);
....@@ -1585,9 +1610,9 @@
15851610 // aConstraints.gridwidth = 1;
15861611
15871612
1588
- ctrlPanel.add(new JSeparator());
1613
+ panel.add(new JSeparator());
15891614
1590
- ctrlPanel.add(specularSection);
1615
+ panel.add(specularSection);
15911616
15921617 //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
15931618
....@@ -1617,9 +1642,9 @@
16171642 opacity.add(opacityField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints);
16181643 globalSection.add(opacity);
16191644
1620
- ctrlPanel.add(new JSeparator());
1645
+ panel.add(new JSeparator());
16211646
1622
- ctrlPanel.add(globalSection);
1647
+ panel.add(globalSection);
16231648
16241649 //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
16251650
....@@ -1661,9 +1686,9 @@
16611686 opacityPower.add(opacityPowerField = new cNumberSlider(this, 0.0, 10 /*10 dec 2013*/)); // , aConstraints);
16621687 textureSection.add(opacityPower);
16631688
1664
- ctrlPanel.add(new JSeparator());
1689
+ panel.add(new JSeparator());
16651690
1666
- ctrlPanel.add(textureSection);
1691
+ panel.add(textureSection);
16671692
16681693 //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints);
16691694
....@@ -2482,6 +2507,7 @@
24822507 }
24832508 if (input == null)
24842509 {
2510
+ new Exception().printStackTrace();
24852511 System.exit(0);
24862512 }
24872513
....@@ -3179,7 +3205,7 @@
31793205 if (!Globals.ANIMATION)
31803206 {
31813207 FileDialog browser = new FileDialog(frame, "Save Animation As...", FileDialog.SAVE);
3182
- browser.show();
3208
+ browser.setVisible(true);
31833209 String filename = browser.getFile();
31843210 if (filename != null && filename.length() > 0)
31853211 {
....@@ -3211,6 +3237,7 @@
32113237 callee.refreshContents();
32123238 } else
32133239 {
3240
+ new Exception().printStackTrace();
32143241 System.exit(0);
32153242 }
32163243 }
....@@ -3421,6 +3448,7 @@
34213448 || e.getSource() == apertureField
34223449 || e.getSource() == shadowblurField)
34233450 {
3451
+ new Exception().printStackTrace();
34243452 System.exit(0);
34253453 cameraView.options1[0] = (float) focusField.getFloat() * 10;
34263454 cameraView.options1[1] = (float) apertureField.getFloat() / 1000;
....@@ -4392,8 +4420,8 @@
43924420 //MenuItem normalLensItem;
43934421 MenuItem editCameraItem;
43944422 MenuItem revertCameraItem;
4395
- CheckboxMenuItem toggleLiveItem;
43964423 MenuItem stepItem;
4424
+ CheckboxMenuItem toggleLiveItem;
43974425 CheckboxMenuItem toggleFullScreenItem;
43984426 CheckboxMenuItem toggleTimelineItem;
43994427 CheckboxMenuItem toggleRenderItem;
....@@ -4410,7 +4438,7 @@
44104438 JSplitPane mainPanel;
44114439 JScrollPane scrollpane;
44124440 JPanel toolbarPanel;
4413
- JPanel treePanel;
4441
+ cGridBag treePanel;
44144442 JPanel radioPanel;
44154443 ButtonGroup buttonGroup;
44164444 cGridBag ctrlPanel;