.. | .. |
---|
19 | 19 | import //weka.core. |
---|
20 | 20 | matrix.Matrix; |
---|
21 | 21 | |
---|
| 22 | +import grafeme.ui.*; |
---|
| 23 | + |
---|
22 | 24 | class ObjEditor /*extends JFrame*/ implements iCallBack, ObjectUI, |
---|
23 | 25 | ActionListener, ChangeListener, |
---|
24 | 26 | InputMethodListener, |
---|
.. | .. |
---|
28 | 30 | iSendInfo |
---|
29 | 31 | //KeyListener |
---|
30 | 32 | { |
---|
| 33 | + boolean timeline; |
---|
| 34 | + boolean wasFullScreen; |
---|
31 | 35 | |
---|
| 36 | + GroupEditor callee; |
---|
| 37 | + JFrame frame; |
---|
| 38 | + |
---|
32 | 39 | // SCRIPT |
---|
33 | 40 | |
---|
34 | 41 | transient JFrame textpanel = null; |
---|
.. | .. |
---|
119 | 126 | void keyPressed(int key, int modifiers) |
---|
120 | 127 | { |
---|
121 | 128 | System.out.println("KEY PRESSED"); |
---|
122 | | - CameraPane.theRenderer.keyPressed(key, modifiers); |
---|
| 129 | + Globals.theRenderer.keyPressed(key, modifiers); |
---|
123 | 130 | } |
---|
124 | 131 | */ |
---|
125 | 132 | |
---|
126 | 133 | static GridBagConstraints aConstraints; |
---|
127 | 134 | static GridBagConstraints aWindowConstraints; |
---|
128 | | - GroupEditor callee; |
---|
129 | | - JFrame frame; |
---|
| 135 | + |
---|
130 | 136 | static int GRIDWIDTH = 100; // 4; |
---|
131 | 137 | |
---|
132 | 138 | public void closeUI() |
---|
133 | 139 | { |
---|
134 | 140 | //new Exception().printStackTrace(); |
---|
135 | | - System.out.println("this = " + this); |
---|
136 | | - System.out.println("objEditor = " + objEditor); |
---|
| 141 | +// System.out.println("this = " + this); |
---|
| 142 | +// System.out.println("objEditor = " + objEditor); |
---|
137 | 143 | //nameField.removeActionListener(this); |
---|
138 | | - objEditor.ctrlPanel.remove(nameField); |
---|
| 144 | +// objEditor.ctrlPanel.remove(nameField); |
---|
139 | 145 | |
---|
140 | 146 | if (!GroupEditor.allparams) |
---|
141 | 147 | return; |
---|
142 | 148 | |
---|
143 | | - objEditor.ctrlPanel.remove(liveCB); |
---|
144 | | - objEditor.ctrlPanel.remove(hideCB); |
---|
145 | | - objEditor.ctrlPanel.remove(markCB); |
---|
146 | | - |
---|
147 | | - objEditor.ctrlPanel.remove(randomCB); |
---|
148 | | - objEditor.ctrlPanel.remove(speedupCB); |
---|
149 | | - objEditor.ctrlPanel.remove(rewindCB); |
---|
150 | | - |
---|
151 | | - objEditor.ctrlPanel.remove(resetButton); |
---|
152 | | - objEditor.ctrlPanel.remove(stepButton); |
---|
153 | | -// objEditor.ctrlPanel.remove(stepAllButton); |
---|
154 | | -// objEditor.ctrlPanel.remove(resetAllButton); |
---|
155 | | - objEditor.ctrlPanel.remove(link2masterCB); |
---|
156 | | - //objEditor.ctrlPanel.remove(flipVCB); |
---|
157 | | - //objEditor.ctrlPanel.remove(texresMenu); |
---|
158 | | - objEditor.ctrlPanel.remove(slowerButton); |
---|
159 | | - objEditor.ctrlPanel.remove(fasterButton); |
---|
160 | | - 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); |
---|
| 167 | + |
---|
| 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); |
---|
161 | 175 | } |
---|
162 | 176 | |
---|
163 | 177 | public ObjEditor GetEditor() |
---|
164 | 178 | { |
---|
165 | 179 | return objEditor; //.GetEditor(); |
---|
166 | 180 | } |
---|
| 181 | + |
---|
| 182 | + // Sometimes myself, sometimes my callee's. |
---|
167 | 183 | ObjEditor objEditor; |
---|
168 | 184 | |
---|
169 | 185 | /* |
---|
.. | .. |
---|
238 | 254 | //if (!isDisplayable()) |
---|
239 | 255 | //setUndecorated(true); |
---|
240 | 256 | |
---|
241 | | - System.out.println("getFullScreenWindow? " + gd.getFullScreenWindow()); |
---|
| 257 | + //System.out.println("getFullScreenWindow? " + gd.getFullScreenWindow()); |
---|
242 | 258 | client = inClient; |
---|
243 | 259 | copy = localCopy; |
---|
244 | 260 | copy.editWindow = this; |
---|
.. | .. |
---|
292 | 308 | //normalLensItem.addActionListener(this); |
---|
293 | 309 | cameraMenu.add(revertCameraItem = new MenuItem("Revert Camera")); |
---|
294 | 310 | revertCameraItem.addActionListener(this); |
---|
| 311 | + cameraMenu.add(toggleTimelineItem = new CheckboxMenuItem("Timeline")); |
---|
| 312 | + toggleTimelineItem.addItemListener(this); |
---|
295 | 313 | cameraMenu.add(toggleFullScreenItem = new CheckboxMenuItem("Full Screen")); |
---|
296 | 314 | toggleFullScreenItem.addItemListener(this); |
---|
297 | 315 | toggleFullScreenItem.setState(CameraPane.FULLSCREEN); |
---|
298 | | - cameraMenu.add(toggleTimelineItem = new CheckboxMenuItem("Timeline")); |
---|
299 | | - toggleTimelineItem.addItemListener(this); |
---|
300 | 316 | cameraMenu.add("-"); |
---|
301 | 317 | cameraMenu.add(toggleTextureItem = new CheckboxMenuItem("Texture")); |
---|
302 | 318 | toggleTextureItem.addItemListener(this); |
---|
303 | 319 | toggleTextureItem.setState(CameraPane.textureon); |
---|
304 | 320 | cameraMenu.add(toggleLiveItem = new CheckboxMenuItem("Live")); |
---|
305 | 321 | toggleLiveItem.addItemListener(this); |
---|
306 | | - toggleLiveItem.setState(CameraPane.isLIVE()); |
---|
| 322 | + toggleLiveItem.setState(Globals.isLIVE()); |
---|
307 | 323 | cameraMenu.add(stepItem = new MenuItem("Step")); |
---|
308 | 324 | stepItem.addActionListener(this); |
---|
309 | 325 | // cameraMenu.add(toggleDLItem = new CheckboxMenuItem("Display List")); |
---|
.. | .. |
---|
345 | 361 | toolbarPanel.setName("Toolbar"); |
---|
346 | 362 | treePanel = new JPanel(); |
---|
347 | 363 | treePanel.setName("Tree"); |
---|
348 | | - ctrlPanel = new JPanel(); // new GridBagLayout()); |
---|
| 364 | + ctrlPanel = new cGridBag().setVertical(false); // new GridBagLayout()); |
---|
349 | 365 | ctrlPanel.setName("Edit"); |
---|
350 | | - materialPanel = new JPanel(); |
---|
| 366 | + materialPanel = new cGridBag().setVertical(true); |
---|
351 | 367 | materialPanel.setName("Material"); |
---|
352 | 368 | /*JTextPane*/ |
---|
353 | 369 | infoarea = createTextPane(); |
---|
.. | .. |
---|
376 | 392 | //mainPanel.setLayout(new GridBagLayout()); |
---|
377 | 393 | toolbarPanel.setLayout(new FlowLayout(FlowLayout.LEFT)); |
---|
378 | 394 | treePanel.setLayout(new GridBagLayout()); |
---|
379 | | - ctrlPanel.setLayout(new GridBagLayout()); |
---|
380 | | - materialPanel.setLayout(new GridBagLayout()); |
---|
| 395 | + //ctrlPanel.setLayout(new GridBagLayout()); |
---|
| 396 | + //materialPanel.setLayout(new GridBagLayout()); |
---|
381 | 397 | |
---|
382 | 398 | aConstraints = new GridBagConstraints(0, 0, 1, 1, 1.0, 1.0, |
---|
383 | 399 | GridBagConstraints.NORTHEAST, GridBagConstraints.BOTH, new Insets(1, 1, 1, 1), 0, 0); |
---|
.. | .. |
---|
596 | 612 | } |
---|
597 | 613 | } |
---|
598 | 614 | |
---|
| 615 | + void ToggleFullScreen() |
---|
| 616 | + { |
---|
| 617 | + if (CameraPane.FULLSCREEN) |
---|
| 618 | + { |
---|
| 619 | + frame.getContentPane().remove(/*"Center",*/bigThree); |
---|
| 620 | + framePanel.add(bigThree); |
---|
| 621 | + frame.getContentPane().add(/*"Center",*/framePanel); |
---|
| 622 | + } else |
---|
| 623 | + { |
---|
| 624 | + frame.getContentPane().remove(/*"Center",*/framePanel); |
---|
| 625 | + framePanel.remove(bigThree); |
---|
| 626 | + frame.getContentPane().add(/*"Center",*/bigThree); |
---|
| 627 | + } |
---|
| 628 | + cameraView.ToggleFullScreen(); |
---|
| 629 | + } |
---|
| 630 | + |
---|
599 | 631 | private JTextArea createTextPane() |
---|
600 | 632 | { |
---|
601 | 633 | String[] initString = |
---|
.. | .. |
---|
741 | 773 | JButton slowerButton; |
---|
742 | 774 | JButton fasterButton; |
---|
743 | 775 | JButton remarkButton; |
---|
| 776 | + |
---|
| 777 | + cGridBag namePanel; |
---|
| 778 | + cGridBag setupPanel; |
---|
| 779 | + cGridBag commandsPanel; |
---|
| 780 | + cGridBag pushPanel; |
---|
| 781 | + cGridBag fillPanel; |
---|
744 | 782 | |
---|
745 | | - JCheckBox AddCheckBox(ObjEditor oe, String label, boolean on) |
---|
| 783 | + JCheckBox AddCheckBox(cGridBag panel, String label, boolean on) |
---|
746 | 784 | { |
---|
747 | 785 | JCheckBox cb; |
---|
748 | 786 | |
---|
749 | | - oe.aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
750 | | - oe.aConstraints.gridwidth = 1; // 3; |
---|
751 | | -// oe.aConstraints.weightx = 1; |
---|
752 | | -// oe.aConstraints.anchor = GridBagConstraints.WEST; |
---|
753 | | - oe.ctrlPanel.add(cb = new JCheckBox(label, on), oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
| 787 | + panel.add(cb = new JCheckBox(label, on)); //, oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
754 | 788 | cb.addItemListener(this); |
---|
755 | | -// oe.aConstraints.anchor = GridBagConstraints.EAST; |
---|
756 | | - oe.aConstraints.gridwidth = 1; |
---|
757 | | - oe.aConstraints.gridx += 1; |
---|
758 | 789 | |
---|
759 | 790 | return cb; |
---|
760 | 791 | } |
---|
761 | 792 | |
---|
762 | | - cButton AddButton(ObjEditor oe, String label) |
---|
| 793 | + cButton AddButton(cGridBag panel, String label) |
---|
763 | 794 | { |
---|
764 | 795 | cButton cb; |
---|
765 | 796 | |
---|
766 | | - oe.aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
767 | | - oe.aConstraints.gridwidth = 1; |
---|
768 | | -// oe.aConstraints.weightx = 1; |
---|
769 | | -// oe.aConstraints.anchor = GridBagConstraints.WEST; |
---|
770 | | - oe.ctrlPanel.add(cb = new cButton(label), oe.aConstraints, oe.ctrlPanel.getComponentCount() - 1); |
---|
| 797 | + panel.add(cb = new cButton(label)); //, oe.aConstraints, oe.ctrlPanel.getComponentCount() - 1); |
---|
771 | 798 | cb.addActionListener(this); |
---|
772 | | -// oe.aConstraints.anchor = GridBagConstraints.EAST; |
---|
773 | | - oe.aConstraints.gridwidth = 1; |
---|
774 | | - oe.aConstraints.gridx += 1; |
---|
775 | 799 | |
---|
776 | 800 | return cb; |
---|
777 | 801 | } |
---|
778 | 802 | |
---|
779 | | - JComboBox AddCombo(ObjEditor oe, java.util.Vector list, int item) |
---|
| 803 | + JComboBox AddCombo(cGridBag panel, java.util.Vector list, int item) |
---|
780 | 804 | { |
---|
781 | 805 | JComboBox combo; |
---|
782 | 806 | |
---|
783 | | - oe.aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
784 | | - oe.ctrlPanel.add(combo = new JComboBox(new cListModel(list, item)), oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
785 | | - oe.aConstraints.gridx += 1; |
---|
| 807 | + panel.add(combo = new JComboBox(new cListModel(list, item))); //, oe.aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
786 | 808 | combo.addActionListener(this); |
---|
787 | 809 | |
---|
788 | 810 | return combo; |
---|
789 | 811 | } |
---|
790 | 812 | |
---|
791 | | - NumberSlider AddSlider(JPanel ctrlPanel, String label, double min, double max, double current, double pow) |
---|
| 813 | + cGridBag AddSlider(cGridBag panel, String label, double min, double max, double current, double pow) |
---|
792 | 814 | { |
---|
793 | | - NumberSlider combo; |
---|
| 815 | + cGridBag control = new cGridBag(); |
---|
| 816 | + |
---|
| 817 | + cNumberSlider combo; |
---|
794 | 818 | |
---|
795 | 819 | JLabel jlabel = new JLabel(label); |
---|
796 | | - |
---|
797 | | - aConstraints.fill = GridBagConstraints.VERTICAL; |
---|
798 | 820 | jlabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
799 | | - aConstraints.gridwidth = 2; |
---|
800 | | - ctrlPanel.add(jlabel, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
801 | | - aConstraints.gridx += 1; |
---|
802 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
803 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
804 | | - ctrlPanel.add(combo = new NumberSlider(min, max, pow), aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
805 | | - aConstraints.gridx += 1; |
---|
806 | | - aConstraints.gridwidth = 1; |
---|
807 | | - |
---|
| 821 | + control.add(jlabel); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
| 822 | + control.add(combo = new cNumberSlider(this, min, max, pow)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
808 | 823 | combo.setFloat(current); |
---|
809 | | - |
---|
810 | | - combo.label = jlabel; |
---|
811 | | - |
---|
812 | | - combo.addChangeListener(this); |
---|
813 | | - |
---|
814 | | - return combo; |
---|
| 824 | + |
---|
| 825 | + panel.add(control); |
---|
| 826 | + |
---|
| 827 | + return control; |
---|
815 | 828 | } |
---|
816 | 829 | |
---|
817 | | - NumberSlider AddSlider(JPanel ctrlPanel, String label, int min, int max, int current) |
---|
| 830 | + cGridBag AddSlider(cGridBag panel, String label, int min, int max, int current) |
---|
818 | 831 | { |
---|
819 | | - NumberSlider combo; |
---|
| 832 | + cGridBag control = new cGridBag(); |
---|
| 833 | + |
---|
| 834 | + cNumberSlider combo; |
---|
820 | 835 | |
---|
821 | 836 | JLabel jlabel = new JLabel(label); |
---|
822 | | - |
---|
823 | | - aConstraints.fill = GridBagConstraints.VERTICAL; |
---|
824 | 837 | jlabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
825 | | - aConstraints.gridwidth = 2; |
---|
826 | | - ctrlPanel.add(jlabel, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
827 | | - aConstraints.gridx += 1; |
---|
828 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
829 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
830 | | - ctrlPanel.add(combo = new NumberSlider(min, max), aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
831 | | - aConstraints.gridx += 1; |
---|
832 | | - aConstraints.gridwidth = 1; |
---|
833 | | - |
---|
| 838 | + control.add(jlabel); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
| 839 | + control.add(combo = new cNumberSlider(this, min, max)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
834 | 840 | combo.setInteger(current); |
---|
835 | 841 | |
---|
836 | | - combo.label = jlabel; |
---|
837 | | - |
---|
838 | | - combo.addChangeListener(this); |
---|
839 | | - |
---|
840 | | - return combo; |
---|
| 842 | + panel.add(control); |
---|
| 843 | + |
---|
| 844 | + return control; |
---|
841 | 845 | } |
---|
842 | 846 | |
---|
843 | | - JTextArea AddText(JPanel ctrlPanel, String name) |
---|
| 847 | + JTextArea AddText(cGridBag ctrlPanel, String name) |
---|
844 | 848 | { |
---|
845 | 849 | JTextArea text; |
---|
846 | 850 | |
---|
847 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
848 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
849 | | - ctrlPanel.add(text = new JTextArea(name), aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
| 851 | + ctrlPanel.add(text = new JTextArea(name)); //, aConstraints); //, oe.ctrlPanel.getComponentCount()-1); |
---|
850 | 852 | text.addCaretListener(this); |
---|
851 | | - aConstraints.gridx += 1; |
---|
852 | | - aConstraints.gridwidth = 1; |
---|
853 | 853 | |
---|
854 | 854 | return text; |
---|
855 | 855 | } |
---|
.. | .. |
---|
879 | 879 | objEditor.ctrlPanel.remove(j); |
---|
880 | 880 | } |
---|
881 | 881 | |
---|
| 882 | + void Remove(cNumberSlider j) |
---|
| 883 | + { |
---|
| 884 | + j.removeChangeListener(this); |
---|
| 885 | + //objEditor.ctrlPanel.remove(j.label); |
---|
| 886 | + objEditor.ctrlPanel.remove(j); |
---|
| 887 | + } |
---|
| 888 | + |
---|
882 | 889 | /* |
---|
883 | 890 | */ |
---|
884 | | - void Return() // ObjEditor oe) |
---|
| 891 | + void Return0() // ObjEditor oe) |
---|
885 | 892 | { |
---|
886 | 893 | aConstraints.gridy += 1; |
---|
887 | 894 | aConstraints.gridx = 0; |
---|
.. | .. |
---|
940 | 947 | // oe.aConstraints.weighty = 0; |
---|
941 | 948 | // oe.aConstraints.gridx = 0; |
---|
942 | 949 | // oe.aConstraints.gridy = 0; |
---|
943 | | - SetupName(oe); |
---|
| 950 | + //SetupName(oe); |
---|
| 951 | + |
---|
| 952 | + namePanel = new cGridBag(); |
---|
| 953 | + |
---|
| 954 | + nameField = AddText(namePanel, copy.GetName()); |
---|
| 955 | + namePanel.add(nameField); |
---|
| 956 | + oe.ctrlPanel.add(namePanel); |
---|
| 957 | + |
---|
| 958 | + oe.ctrlPanel.Return(); |
---|
944 | 959 | |
---|
945 | 960 | if (!GroupEditor.allparams) |
---|
946 | 961 | return; |
---|
947 | 962 | |
---|
948 | | - liveCB = AddCheckBox(oe, "Live", copy.live); |
---|
949 | | - link2masterCB = AddCheckBox(oe, "Supp", copy.link2master); |
---|
950 | | - hideCB = AddCheckBox(oe, "Hide", copy.hide); |
---|
| 963 | + setupPanel = new cGridBag().setVertical(false); |
---|
| 964 | + |
---|
| 965 | + liveCB = AddCheckBox(setupPanel, "Live", copy.live); |
---|
| 966 | + link2masterCB = AddCheckBox(setupPanel, "Supp", copy.link2master); |
---|
| 967 | + hideCB = AddCheckBox(setupPanel, "Hide", copy.hide); |
---|
951 | 968 | // Return(); |
---|
952 | | - markCB = AddCheckBox(oe, "Mark", copy.marked); |
---|
953 | | - rewindCB = AddCheckBox(oe, "Rew", copy.rewind); |
---|
954 | | - randomCB = AddCheckBox(oe, "Rand", copy.random); |
---|
955 | | - Return(); |
---|
956 | | - resetButton = AddButton(oe, "Reset"); |
---|
957 | | - stepButton = AddButton(oe, "Step"); |
---|
| 969 | + markCB = AddCheckBox(setupPanel, "Mark", copy.marked); |
---|
| 970 | + rewindCB = AddCheckBox(setupPanel, "Rew", copy.rewind); |
---|
| 971 | + randomCB = AddCheckBox(setupPanel, "Rand", copy.random); |
---|
| 972 | + |
---|
| 973 | + oe.ctrlPanel.add(setupPanel); |
---|
| 974 | + oe.ctrlPanel.Return(); |
---|
| 975 | + |
---|
| 976 | + commandsPanel = new cGridBag().setVertical(false); |
---|
| 977 | + |
---|
| 978 | + resetButton = AddButton(commandsPanel, "Reset"); |
---|
| 979 | + stepButton = AddButton(commandsPanel, "Step"); |
---|
958 | 980 | // resetAllButton = AddButton(oe, "Reset All"); |
---|
959 | 981 | // stepAllButton = AddButton(oe, "Step All"); |
---|
960 | | - speedupCB = AddCheckBox(oe, "Speed", copy.speedup); |
---|
| 982 | + speedupCB = AddCheckBox(commandsPanel, "Speed", copy.speedup); |
---|
961 | 983 | // Return(); |
---|
962 | | - slowerButton = AddButton(oe, "Slow"); |
---|
963 | | - fasterButton = AddButton(oe, "Fast"); |
---|
964 | | - remarkButton = AddButton(oe, "Rem"); |
---|
| 984 | + slowerButton = AddButton(commandsPanel, "Slow"); |
---|
| 985 | + fasterButton = AddButton(commandsPanel, "Fast"); |
---|
| 986 | + remarkButton = AddButton(commandsPanel, "Remark"); |
---|
965 | 987 | |
---|
966 | | - Return(); |
---|
| 988 | + oe.ctrlPanel.add(commandsPanel); |
---|
| 989 | + oe.ctrlPanel.Return(); |
---|
967 | 990 | |
---|
| 991 | + pushPanel = AddSlider(oe.ctrlPanel, "Push", -10, 10, 0, 1); |
---|
| 992 | + normalpushField = (cNumberSlider)pushPanel.getComponent(1); |
---|
| 993 | + //Return(); |
---|
| 994 | + |
---|
| 995 | + oe.ctrlPanel.Return(); |
---|
| 996 | + |
---|
968 | 997 | // oe.ctrlPanel.add(stepButton = new cButton("Step"), ObjEditor.aConstraints, oe.ctrlPanel.getComponentCount() - 2); |
---|
969 | 998 | // ObjEditor.aConstraints.gridx += 1; |
---|
970 | 999 | |
---|
.. | .. |
---|
1058 | 1087 | oe.aConstraints.gridwidth = 1; |
---|
1059 | 1088 | /**/ |
---|
1060 | 1089 | nameField = AddText(oe.ctrlPanel, copy.GetName()); |
---|
1061 | | - Return(); |
---|
| 1090 | + oe.ctrlPanel.Return(); |
---|
1062 | 1091 | |
---|
1063 | 1092 | //ctrlPanel.add(textureButton = new Button("Texture...")); |
---|
1064 | 1093 | //textureButton.setEnabled(false); |
---|
.. | .. |
---|
1160 | 1189 | //JPanel worldPanel = |
---|
1161 | 1190 | // new gov.nasa.worldwind.examples.ApplicationTemplate.AppPanel(null, true); |
---|
1162 | 1191 | //worldPanel.setName("World"); |
---|
1163 | | - centralPanel = new JPanel(new BorderLayout()); |
---|
| 1192 | + centralPanel = new cGridBag(); |
---|
| 1193 | + centralPanel.preferredWidth = 20; |
---|
1164 | 1194 | timelinePanel = new JPanel(new BorderLayout()); |
---|
1165 | 1195 | timelineMenubar = new timeflow.app.TimeflowApp().TimeFlowWindow(timelinePanel); |
---|
1166 | 1196 | |
---|
| 1197 | + cameraPanel = new JSplitPane(JSplitPane.VERTICAL_SPLIT, cameraView, timelinePanel); |
---|
| 1198 | + cameraPanel.setContinuousLayout(true); |
---|
| 1199 | + cameraPanel.setOneTouchExpandable(true); |
---|
| 1200 | +// cameraPanel.setDividerLocation(0.9); |
---|
| 1201 | +// cameraPanel.setDividerSize(9); |
---|
| 1202 | + cameraPanel.setResizeWeight(1.0); |
---|
| 1203 | + |
---|
1167 | 1204 | centralPanel.add(cameraView); |
---|
1168 | 1205 | //frame.setJMenuBar(timelineMenubar); |
---|
1169 | 1206 | //centralPanel.add(timelinePanel); |
---|
.. | .. |
---|
1183 | 1220 | //frontView.object = copy; |
---|
1184 | 1221 | //sideView.object = copy; |
---|
1185 | 1222 | |
---|
1186 | | - XYZPanel = new JPanel(); |
---|
1187 | | - XYZPanel.setLayout(new GridLayout(3, 1, 5, 5)); |
---|
| 1223 | + XYZPanel = new cGridBag().setVertical(true); |
---|
| 1224 | + //XYZPanel.setLayout(new GridLayout(3, 1, 5, 5)); |
---|
1188 | 1225 | |
---|
1189 | | - XYZPanel.add(/*BorderLayout.SOUTH,*/sideView); // Scroll); |
---|
1190 | | - XYZPanel.add(/*BorderLayout.CENTER,*/frontView); // Scroll); |
---|
1191 | | - XYZPanel.add(/*BorderLayout.NORTH,*/topView); // Scroll); |
---|
| 1226 | + XYZPanel.preferredWidth = 5; |
---|
| 1227 | + XYZPanel.addComponent(/*BorderLayout.SOUTH,*/sideView); // Scroll); |
---|
| 1228 | + XYZPanel.addComponent(/*BorderLayout.CENTER,*/frontView); // Scroll); |
---|
| 1229 | + XYZPanel.addComponent(/*BorderLayout.NORTH,*/topView); // Scroll); |
---|
1192 | 1230 | |
---|
1193 | 1231 | /* |
---|
1194 | 1232 | gridPanel = new JPanel(); //new BorderLayout()); |
---|
.. | .. |
---|
1226 | 1264 | //JScrollPane tmp = new JScrollPane(ctrlPanel, ScrollPaneConstants.VERTICAL_SCROLLBAR_AS_NEEDED, ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER); |
---|
1227 | 1265 | //tmp.setName("Edit"); |
---|
1228 | 1266 | objectPanel.add(materialPanel); |
---|
1229 | | - JPanel north = new JPanel(new BorderLayout()); |
---|
1230 | | - north.setName("Edit"); |
---|
1231 | | - north.add(ctrlPanel, BorderLayout.NORTH); |
---|
1232 | | - objectPanel.add(north); |
---|
| 1267 | +// JPanel north = new JPanel(new BorderLayout()); |
---|
| 1268 | +// north.setName("Edit"); |
---|
| 1269 | +// north.add(ctrlPanel, BorderLayout.NORTH); |
---|
| 1270 | +// objectPanel.add(north); |
---|
| 1271 | + objectPanel.add(ctrlPanel); |
---|
1233 | 1272 | objectPanel.add(infoPanel); |
---|
1234 | 1273 | |
---|
1235 | 1274 | /* |
---|
.. | .. |
---|
1250 | 1289 | scrollpane.setWheelScrollingEnabled(true); |
---|
1251 | 1290 | scrollpane.addMouseWheelListener(this); // Default not fast enough |
---|
1252 | 1291 | |
---|
1253 | | - /*JTabbedPane*/ scenePanel = new JTabbedPane(); |
---|
1254 | | - scenePanel.add(scrollpane); |
---|
| 1292 | + /*JTabbedPane*/ scenePanel = new cGridBag(); |
---|
| 1293 | + scenePanel.preferredWidth = 7; |
---|
| 1294 | + |
---|
| 1295 | + JTabbedPane tabbedPane = new JTabbedPane(); |
---|
| 1296 | + tabbedPane.add(scrollpane); |
---|
1255 | 1297 | |
---|
1256 | | - scenePanel.add(FSPane = new cFileSystemPane(this)); |
---|
| 1298 | + tabbedPane.add(FSPane = new cFileSystemPane(this)); |
---|
1257 | 1299 | |
---|
1258 | | - optionsPanel = new JPanel(new GridBagLayout()); |
---|
| 1300 | + optionsPanel = new cGridBag().setVertical(true); |
---|
1259 | 1301 | |
---|
1260 | 1302 | optionsPanel.setName("Options"); |
---|
1261 | | - scenePanel.add(optionsPanel); |
---|
1262 | | - |
---|
| 1303 | + |
---|
| 1304 | + AddOptions(optionsPanel); //, aConstraints); |
---|
| 1305 | + |
---|
| 1306 | + tabbedPane.add(optionsPanel); |
---|
| 1307 | + |
---|
| 1308 | + scenePanel.add(tabbedPane); |
---|
1263 | 1309 | |
---|
1264 | 1310 | /* |
---|
1265 | 1311 | cTree jTree = new cTree(null); |
---|
.. | .. |
---|
1293 | 1339 | //bigPanel.setSize(new Dimension(10,10)); |
---|
1294 | 1340 | //bigPanel.add(ctrlPanel); |
---|
1295 | 1341 | //bigPanel.add(gridPanel); |
---|
| 1342 | + /** |
---|
1296 | 1343 | bigThree = new JPanel(); |
---|
1297 | 1344 | //big.setLayout(new FlowLayout(FlowLayout.LEFT)); |
---|
1298 | 1345 | bigThree.setLayout(new GridBagLayout()); //1,3,5,5)); |
---|
.. | .. |
---|
1316 | 1363 | // aConstraints.gridheight = 3; |
---|
1317 | 1364 | aWindowConstraints.fill = GridBagConstraints.VERTICAL; |
---|
1318 | 1365 | bigThree.add(XYZPanel, aWindowConstraints); |
---|
| 1366 | + /**/ |
---|
1319 | 1367 | |
---|
| 1368 | + bigThree = new cGridBag(); |
---|
| 1369 | + bigThree.addComponent(scenePanel); |
---|
| 1370 | + bigThree.addComponent(centralPanel); |
---|
| 1371 | + bigThree.addComponent(XYZPanel); |
---|
| 1372 | + |
---|
1320 | 1373 | // // SIDE EFFECT!!! |
---|
1321 | 1374 | // aConstraints.gridx = 0; |
---|
1322 | 1375 | // aConstraints.gridy = 0; |
---|
.. | .. |
---|
1337 | 1390 | //worldPane.add(bigPanel); |
---|
1338 | 1391 | //worldPane.add(worldPanel); |
---|
1339 | 1392 | /**/ |
---|
1340 | | - frame.getContentPane().add(/*"Center",*/framePanel); |
---|
| 1393 | + //frame.getContentPane().add(/*"Center",*/framePanel); |
---|
| 1394 | + frame.add(/*"Center",*/framePanel); |
---|
1341 | 1395 | //frame.getContentPane().add(/*"Center",*/ worldPane); |
---|
1342 | 1396 | |
---|
1343 | 1397 | // aConstraints = gbc; // (GridBagConstraints) GrafreeD.clone(gbc); |
---|
.. | .. |
---|
1358 | 1412 | }); |
---|
1359 | 1413 | } |
---|
1360 | 1414 | |
---|
| 1415 | + void AddOptions(cGridBag panel) //, GridBagConstraints constraints) |
---|
| 1416 | + { |
---|
| 1417 | + } |
---|
| 1418 | + |
---|
1361 | 1419 | JTree GetTree() |
---|
1362 | 1420 | { |
---|
1363 | 1421 | return objEditor.jTree; |
---|
.. | .. |
---|
1369 | 1427 | ctrlPanel.removeAll(); |
---|
1370 | 1428 | } |
---|
1371 | 1429 | |
---|
1372 | | - void SetupMaterial(JPanel ctrlPanel) |
---|
| 1430 | + void SetupMaterial(cGridBag panel) |
---|
1373 | 1431 | { |
---|
1374 | | - aConstraints.weighty = 0; |
---|
1375 | | - //aConstraints.weightx = 1; |
---|
1376 | | - /* |
---|
| 1432 | + /* |
---|
1377 | 1433 | ctrlPanel.add(materialLabel = new JLabel("MATERIAL : "), aConstraints); |
---|
1378 | 1434 | materialLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1379 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1380 | | - aConstraints.gridx += 1; |
---|
1381 | 1435 | */ |
---|
1382 | 1436 | |
---|
1383 | | - aConstraints.gridwidth = 1; |
---|
1384 | | - ctrlPanel.add(createMaterialButton = new cButton("Create"), aConstraints); |
---|
1385 | | - aConstraints.gridx += 1; |
---|
1386 | | - aConstraints.weighty = 0; |
---|
1387 | | - aConstraints.gridwidth = 1; |
---|
| 1437 | + cGridBag editBar = new cGridBag().setVertical(false); |
---|
| 1438 | + |
---|
| 1439 | + editBar.add(createMaterialButton = new cButton("Create")); // , aConstraints); |
---|
1388 | 1440 | |
---|
1389 | 1441 | /* |
---|
1390 | 1442 | ctrlPanel.add(resetSlidersButton = new cButton("Reset All"), aConstraints); |
---|
1391 | | - aConstraints.gridx += 1; |
---|
1392 | | - aConstraints.weighty = 0; |
---|
1393 | | - aConstraints.gridwidth = 1; |
---|
1394 | 1443 | */ |
---|
1395 | 1444 | |
---|
1396 | | - ctrlPanel.add(clearMaterialButton = new cButton("Clear"), aConstraints); |
---|
1397 | | - aConstraints.gridx += 1; |
---|
| 1445 | + editBar.add(clearMaterialButton = new cButton("Clear")); // , aConstraints); |
---|
| 1446 | + editBar.add(resetSlidersButton = new cButton("Reset")); // , aConstraints); |
---|
| 1447 | + editBar.add(propagateToggle = new cCheckBox("Prop", propagate)); // , aConstraints); |
---|
| 1448 | + editBar.add(multiplyToggle = new cCheckBox("Mult", false)); // , aConstraints); |
---|
1398 | 1449 | |
---|
1399 | | - ctrlPanel.add(resetSlidersButton = new cButton("Reset"), aConstraints); |
---|
1400 | | - |
---|
1401 | | - aConstraints.gridx += 1; |
---|
1402 | | - |
---|
1403 | | - ctrlPanel.add(propagateToggle = new cCheckBox("Prop", propagate), aConstraints); |
---|
1404 | | - |
---|
1405 | | - aConstraints.gridx += 1; |
---|
1406 | | - |
---|
1407 | | - ctrlPanel.add(multiplyToggle = new cCheckBox("Mult", false), aConstraints); |
---|
1408 | | - |
---|
1409 | | - aConstraints.gridx = 0; |
---|
1410 | | - aConstraints.gridy += 1; |
---|
1411 | | - aConstraints.weighty = 0; |
---|
1412 | | - aConstraints.gridwidth = 1; |
---|
| 1450 | + panel.add(editBar); |
---|
| 1451 | + |
---|
1413 | 1452 | /**/ |
---|
1414 | 1453 | //aConstraints.weighty = 0; |
---|
1415 | 1454 | ////aConstraints.weightx = 1; |
---|
1416 | 1455 | //aConstraints.weighty = 1; |
---|
1417 | 1456 | aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100; |
---|
1418 | 1457 | //aConstraints.gridx += 1; |
---|
1419 | | - ctrlPanel.add(new JLabel("----------------------------------"), aConstraints); |
---|
1420 | | - aConstraints.weighty = 0; |
---|
1421 | | - aConstraints.gridx = 0; |
---|
1422 | | - aConstraints.gridy += 1; |
---|
1423 | | - aConstraints.gridwidth = 1; |
---|
| 1458 | + //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints); |
---|
1424 | 1459 | |
---|
1425 | | - ctrlPanel.add(colorLabel = new JLabel("Color/hue"), aConstraints); |
---|
1426 | | - colorLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1427 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1428 | | - aConstraints.gridx += 1; |
---|
1429 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1430 | | - //aConstraints.weightx = 0; |
---|
1431 | | - ctrlPanel.add(colorField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1432 | | - aConstraints.gridx = 0; |
---|
1433 | | - aConstraints.gridy += 1; |
---|
1434 | | - aConstraints.gridwidth = 1; |
---|
| 1460 | + cGridBag colorSection = new cGridBag().setVertical(true); |
---|
| 1461 | + |
---|
| 1462 | + cGridBag color = new cGridBag(); |
---|
| 1463 | + color.add(colorLabel = new JLabel("Color/hue")); // , aConstraints); |
---|
| 1464 | + colorLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1465 | + color.add(colorField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1466 | + //colorField.preferredWidth = 200; |
---|
| 1467 | + colorSection.add(color); |
---|
1435 | 1468 | |
---|
1436 | | - ctrlPanel.add(modulationLabel = new JLabel("Saturation"), aConstraints); |
---|
1437 | | - modulationLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1438 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1439 | | - aConstraints.gridx += 1; |
---|
1440 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1441 | | - ctrlPanel.add(modulationField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1442 | | - aConstraints.gridx = 0; |
---|
1443 | | - aConstraints.gridy += 1; |
---|
1444 | | - aConstraints.gridwidth = 1; |
---|
| 1469 | + cGridBag modulation = new cGridBag(); |
---|
| 1470 | + modulation.add(modulationLabel = new JLabel("Saturation")); // , aConstraints); |
---|
| 1471 | + modulationLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1472 | + modulation.add(modulationField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1473 | + colorSection.add(modulation); |
---|
1445 | 1474 | |
---|
1446 | | - ctrlPanel.add(textureLabel = new JLabel("Texture"), aConstraints); |
---|
1447 | | - textureLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1448 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1449 | | - aConstraints.gridx += 1; |
---|
1450 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1451 | | - ctrlPanel.add(textureField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1452 | | - aConstraints.gridx = 0; |
---|
1453 | | - aConstraints.gridy += 1; |
---|
1454 | | - aConstraints.gridwidth = 1; |
---|
| 1475 | + cGridBag texture = new cGridBag(); |
---|
| 1476 | + texture.add(textureLabel = new JLabel("Texture")); // , aConstraints); |
---|
| 1477 | + textureLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1478 | + texture.add(textureField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1479 | + colorSection.add(texture); |
---|
1455 | 1480 | |
---|
1456 | | - ctrlPanel.add(anisoLabel = new JLabel("AnisoU"), aConstraints); |
---|
1457 | | - anisoLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1458 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1459 | | - aConstraints.gridx += 1; |
---|
1460 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1461 | | - ctrlPanel.add(anisoField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1462 | | - aConstraints.gridx = 0; |
---|
1463 | | - aConstraints.gridy += 1; |
---|
1464 | | - aConstraints.gridwidth = 1; |
---|
| 1481 | + cGridBag anisoU = new cGridBag(); |
---|
| 1482 | + anisoU.add(anisoLabel = new JLabel("AnisoU")); // , aConstraints); |
---|
| 1483 | + anisoLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1484 | + anisoU.add(anisoField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1485 | + colorSection.add(anisoU); |
---|
1465 | 1486 | |
---|
1466 | | - ctrlPanel.add(anisoVLabel = new JLabel("AnisoV"), aConstraints); |
---|
1467 | | - anisoVLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1468 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1469 | | - aConstraints.gridx += 1; |
---|
1470 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1471 | | - ctrlPanel.add(anisoVField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1472 | | - aConstraints.gridx = 0; |
---|
1473 | | - aConstraints.gridy += 1; |
---|
1474 | | - aConstraints.gridwidth = 1; |
---|
| 1487 | + cGridBag anisoV = new cGridBag(); |
---|
| 1488 | + anisoV.add(anisoVLabel = new JLabel("AnisoV")); // , aConstraints); |
---|
| 1489 | + anisoVLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1490 | + anisoV.add(anisoVField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1491 | + colorSection.add(anisoV); |
---|
1475 | 1492 | |
---|
1476 | | - ctrlPanel.add(shadowbiasLabel = new JLabel("Shadowbias"), aConstraints); |
---|
1477 | | - shadowbiasLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1478 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1479 | | - aConstraints.gridx += 1; |
---|
1480 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1481 | | - ctrlPanel.add(shadowbiasField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1482 | | - aConstraints.gridx = 0; |
---|
1483 | | - aConstraints.gridy += 1; |
---|
1484 | | - aConstraints.gridwidth = 1; |
---|
| 1493 | + cGridBag shadowbias = new cGridBag(); |
---|
| 1494 | + shadowbias.add(shadowbiasLabel = new JLabel("Shadowbias")); // , aConstraints); |
---|
| 1495 | + shadowbiasLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1496 | + shadowbias.add(shadowbiasField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1497 | + colorSection.add(shadowbias); |
---|
1485 | 1498 | |
---|
1486 | | - //aConstraints.weighty = 1; |
---|
1487 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100; |
---|
1488 | | - //aConstraints.gridx += 1; |
---|
1489 | | - ctrlPanel.add(new JLabel("----------------------------------"), aConstraints); |
---|
1490 | | - aConstraints.weighty = 0; |
---|
1491 | | - aConstraints.gridx = 0; |
---|
1492 | | - aConstraints.gridy += 1; |
---|
1493 | | - aConstraints.gridwidth = 1; |
---|
| 1499 | + panel.add(new JSeparator()); |
---|
| 1500 | + |
---|
| 1501 | + panel.add(colorSection); |
---|
| 1502 | + |
---|
| 1503 | + //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints); |
---|
| 1504 | + |
---|
| 1505 | + cGridBag diffuseSection = new cGridBag().setVertical(true); |
---|
| 1506 | + |
---|
| 1507 | + cGridBag diffuse = new cGridBag(); |
---|
| 1508 | + diffuse.add(diffuseLabel = new JLabel("Diffuse")); // , aConstraints); |
---|
| 1509 | + diffuseLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1510 | + diffuse.add(diffuseField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1511 | + diffuseSection.add(diffuse); |
---|
1494 | 1512 | |
---|
1495 | | - ctrlPanel.add(diffuseLabel = new JLabel("Diffuse"), aConstraints); |
---|
1496 | | - diffuseLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1497 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1498 | | - aConstraints.gridx += 1; |
---|
1499 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1500 | | - ctrlPanel.add(diffuseField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1501 | | - aConstraints.gridx = 0; |
---|
1502 | | - aConstraints.gridy += 1; |
---|
1503 | | - aConstraints.gridwidth = 1; |
---|
| 1513 | + cGridBag diffuseness = new cGridBag(); |
---|
| 1514 | + diffuseness.add(diffusenessLabel = new JLabel("Diffusion")); // , aConstraints); |
---|
| 1515 | + diffusenessLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1516 | + diffuseness.add(diffusenessField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1517 | + diffuseSection.add(diffuseness); |
---|
1504 | 1518 | |
---|
1505 | | - ctrlPanel.add(diffusenessLabel = new JLabel("Diffusion"), aConstraints); |
---|
1506 | | - diffusenessLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1507 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1508 | | - aConstraints.gridx += 1; |
---|
1509 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1510 | | - ctrlPanel.add(diffusenessField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1511 | | - aConstraints.gridx = 0; |
---|
1512 | | - aConstraints.gridy += 1; |
---|
1513 | | - aConstraints.gridwidth = 1; |
---|
| 1519 | + cGridBag selfshadow = new cGridBag(); |
---|
| 1520 | + selfshadow.add(selfshadowLabel = new JLabel("Selfshadow")); // , aConstraints); |
---|
| 1521 | + selfshadowLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1522 | + selfshadow.add(selfshadowField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1523 | + diffuseSection.add(selfshadow); |
---|
1514 | 1524 | |
---|
1515 | | - ctrlPanel.add(selfshadowLabel = new JLabel("Selfshadow"), aConstraints); |
---|
1516 | | - selfshadowLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1517 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1518 | | - aConstraints.gridx += 1; |
---|
1519 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1520 | | - ctrlPanel.add(selfshadowField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1521 | | - aConstraints.gridx = 0; |
---|
1522 | | - aConstraints.gridy += 1; |
---|
1523 | | - aConstraints.gridwidth = 1; |
---|
| 1525 | + cGridBag sheen = new cGridBag(); |
---|
| 1526 | + sheen.add(sheenLabel = new JLabel("Sheen")); // , aConstraints); |
---|
| 1527 | + sheenLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1528 | + sheen.add(sheenField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1529 | + diffuseSection.add(sheen); |
---|
1524 | 1530 | |
---|
1525 | | - ctrlPanel.add(sheenLabel = new JLabel("Sheen"), aConstraints); |
---|
1526 | | - sheenLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1527 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1528 | | - aConstraints.gridx += 1; |
---|
1529 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1530 | | - ctrlPanel.add(sheenField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1531 | | - aConstraints.gridx = 0; |
---|
1532 | | - aConstraints.gridy += 1; |
---|
1533 | | - aConstraints.gridwidth = 1; |
---|
| 1531 | + cGridBag subsurface = new cGridBag(); |
---|
| 1532 | + subsurface.add(subsurfaceLabel = new JLabel("Subsurface")); // , aConstraints); |
---|
| 1533 | + subsurfaceLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1534 | + subsurface.add(subsurfaceField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1535 | + diffuseSection.add(subsurface); |
---|
1534 | 1536 | |
---|
1535 | | - ctrlPanel.add(subsurfaceLabel = new JLabel("Subsurface"), aConstraints); |
---|
1536 | | - subsurfaceLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1537 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1538 | | - aConstraints.gridx += 1; |
---|
1539 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1540 | | - ctrlPanel.add(subsurfaceField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1541 | | - aConstraints.gridx = 0; |
---|
1542 | | - aConstraints.gridy += 1; |
---|
1543 | | - aConstraints.gridwidth = 1; |
---|
| 1537 | + cGridBag shadow = new cGridBag(); |
---|
| 1538 | + shadow.add(shadowLabel = new JLabel("Shadowing")); // , aConstraints); |
---|
| 1539 | + shadowLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1540 | + shadow.add(shadowField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1541 | + diffuseSection.add(shadow); |
---|
1544 | 1542 | |
---|
1545 | | - ctrlPanel.add(shadowLabel = new JLabel("Shadowing"), aConstraints); |
---|
1546 | | - shadowLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1547 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1548 | | - aConstraints.gridx += 1; |
---|
1549 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1550 | | - ctrlPanel.add(shadowField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1551 | | - aConstraints.gridx = 0; |
---|
1552 | | - aConstraints.gridy += 1; |
---|
1553 | | - aConstraints.gridwidth = 1; |
---|
| 1543 | + cGridBag fakedepth = new cGridBag(); |
---|
| 1544 | + fakedepth.add(fakedepthLabel = new JLabel("Fakedepth")); // , aConstraints); |
---|
| 1545 | + fakedepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1546 | + fakedepth.add(fakedepthField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1547 | + diffuseSection.add(fakedepth); |
---|
1554 | 1548 | |
---|
1555 | | - ctrlPanel.add(fakedepthLabel = new JLabel("Fakedepth"), aConstraints); |
---|
1556 | | - fakedepthLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1557 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1558 | | - aConstraints.gridx += 1; |
---|
1559 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1560 | | - ctrlPanel.add(fakedepthField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1561 | | - aConstraints.gridx = 0; |
---|
1562 | | - aConstraints.gridy += 1; |
---|
1563 | | - aConstraints.gridwidth = 1; |
---|
| 1549 | + panel.add(new JSeparator()); |
---|
| 1550 | + |
---|
| 1551 | + panel.add(diffuseSection); |
---|
| 1552 | + |
---|
| 1553 | + //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints); |
---|
| 1554 | + |
---|
| 1555 | + cGridBag specularSection = new cGridBag().setVertical(true); |
---|
1564 | 1556 | |
---|
1565 | | - //aConstraints.weighty = 1; |
---|
1566 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100; |
---|
1567 | | - //aConstraints.gridx += 1; |
---|
1568 | | - ctrlPanel.add(new JLabel("----------------------------------"), aConstraints); |
---|
1569 | | - aConstraints.weighty = 0; |
---|
1570 | | - aConstraints.gridx = 0; |
---|
1571 | | - aConstraints.gridy += 1; |
---|
1572 | | - aConstraints.gridwidth = 1; |
---|
| 1557 | + cGridBag specular = new cGridBag(); |
---|
| 1558 | + specular.add(specularLabel = new JLabel("Specular")); // , aConstraints); |
---|
| 1559 | + specularLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1560 | + specular.add(specularField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1561 | + specularSection.add(specular); |
---|
1573 | 1562 | |
---|
1574 | | - ctrlPanel.add(specularLabel = new JLabel("Specular"), aConstraints); |
---|
1575 | | - specularLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1576 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1577 | | - aConstraints.gridx += 1; |
---|
1578 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1579 | | - ctrlPanel.add(specularField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1580 | | - aConstraints.gridx = 0; |
---|
1581 | | - aConstraints.gridy += 1; |
---|
1582 | | - aConstraints.gridwidth = 1; |
---|
| 1563 | + cGridBag lightarea = new cGridBag(); |
---|
| 1564 | + lightarea.add(lightareaLabel = new JLabel("Lightarea")); // , aConstraints); |
---|
| 1565 | + lightareaLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1566 | + lightarea.add(lightareaField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1567 | + specularSection.add(lightarea); |
---|
1583 | 1568 | |
---|
1584 | | - ctrlPanel.add(lightareaLabel = new JLabel("Lightarea"), aConstraints); |
---|
1585 | | - lightareaLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1586 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1587 | | - aConstraints.gridx += 1; |
---|
1588 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1589 | | - ctrlPanel.add(lightareaField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1590 | | - aConstraints.gridx = 0; |
---|
1591 | | - aConstraints.gridy += 1; |
---|
1592 | | - aConstraints.gridwidth = 1; |
---|
| 1569 | + cGridBag shininess = new cGridBag(); |
---|
| 1570 | + shininess.add(shininessLabel = new JLabel("Roughness")); // , aConstraints); |
---|
| 1571 | + shininessLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1572 | + shininess.add(shininessField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1573 | + specularSection.add(shininess); |
---|
1593 | 1574 | |
---|
1594 | | - ctrlPanel.add(shininessLabel = new JLabel("Roughness"), aConstraints); |
---|
1595 | | - shininessLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1596 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1597 | | - aConstraints.gridx += 1; |
---|
1598 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1599 | | - ctrlPanel.add(shininessField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1600 | | - aConstraints.gridx = 0; |
---|
1601 | | - aConstraints.gridy += 1; |
---|
1602 | | - aConstraints.gridwidth = 1; |
---|
| 1575 | + cGridBag metalness = new cGridBag(); |
---|
| 1576 | + metalness.add(metalnessLabel = new JLabel("Metalness")); // , aConstraints); |
---|
| 1577 | + metalnessLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1578 | + metalness.add(metalnessField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1579 | + specularSection.add(metalness); |
---|
1603 | 1580 | |
---|
1604 | | - ctrlPanel.add(metalnessLabel = new JLabel("Metalness"), aConstraints); |
---|
1605 | | - metalnessLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1606 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1607 | | - aConstraints.gridx += 1; |
---|
1608 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1609 | | - ctrlPanel.add(metalnessField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1610 | | - aConstraints.gridx = 0; |
---|
1611 | | - aConstraints.gridy += 1; |
---|
1612 | | - aConstraints.gridwidth = 1; |
---|
| 1581 | + cGridBag velvet = new cGridBag(); |
---|
| 1582 | + velvet.add(velvetLabel = new JLabel("Velvet")); // , aConstraints); |
---|
| 1583 | + velvetLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1584 | + velvet.add(velvetField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1585 | + specularSection.add(velvet); |
---|
1613 | 1586 | |
---|
1614 | | - ctrlPanel.add(velvetLabel = new JLabel("Velvet"), aConstraints); |
---|
1615 | | - velvetLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1616 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1617 | | - aConstraints.gridx += 1; |
---|
1618 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1619 | | - ctrlPanel.add(velvetField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1620 | | - aConstraints.gridx = 0; |
---|
1621 | | - aConstraints.gridy += 1; |
---|
1622 | | - aConstraints.gridwidth = 1; |
---|
1623 | | - |
---|
1624 | | - shiftField = AddSlider(ctrlPanel, "Shift", 0.001, 50, copy.material.shift, -1); |
---|
1625 | | - Return(); |
---|
| 1587 | + shiftField = (cNumberSlider)AddSlider(specularSection, "Shift", 0.001, 50, copy.material.shift, -1).getComponent(1); |
---|
| 1588 | + //Return(); |
---|
1626 | 1589 | // ctrlPanel.add(shiftLabel = new JLabel("Shift"), aConstraints); |
---|
1627 | 1590 | // shiftLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1628 | 1591 | // aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
.. | .. |
---|
1633 | 1596 | // aConstraints.gridy += 1; |
---|
1634 | 1597 | // aConstraints.gridwidth = 1; |
---|
1635 | 1598 | |
---|
1636 | | - //aConstraints.weighty = 1; |
---|
1637 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100; |
---|
1638 | | - //aConstraints.gridx += 1; |
---|
1639 | | - ctrlPanel.add(new JLabel("----------------------------------"), aConstraints); |
---|
1640 | | - aConstraints.weighty = 0; |
---|
1641 | | - aConstraints.gridx = 0; |
---|
1642 | | - aConstraints.gridy += 1; |
---|
1643 | | - aConstraints.gridwidth = 1; |
---|
1644 | 1599 | |
---|
1645 | | - ctrlPanel.add(cameraLabel = new JLabel("GlobalLight"), aConstraints); |
---|
1646 | | - cameraLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1647 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1648 | | - aConstraints.gridx += 1; |
---|
1649 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1650 | | - ctrlPanel.add(cameraField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1651 | | - aConstraints.gridx = 0; |
---|
1652 | | - aConstraints.gridy += 1; |
---|
1653 | | - aConstraints.gridwidth = 1; |
---|
| 1600 | + panel.add(new JSeparator()); |
---|
| 1601 | + |
---|
| 1602 | + panel.add(specularSection); |
---|
| 1603 | + |
---|
| 1604 | + //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints); |
---|
| 1605 | + |
---|
| 1606 | + cGridBag globalSection = new cGridBag().setVertical(true); |
---|
1654 | 1607 | |
---|
1655 | | - ctrlPanel.add(ambientLabel = new JLabel("Ambient"), aConstraints); |
---|
1656 | | - ambientLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1657 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1658 | | - aConstraints.gridx += 1; |
---|
1659 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1660 | | - ctrlPanel.add(ambientField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1661 | | - aConstraints.gridx = 0; |
---|
1662 | | - aConstraints.gridy += 1; |
---|
1663 | | - aConstraints.gridwidth = 1; |
---|
| 1608 | + cGridBag camera = new cGridBag(); |
---|
| 1609 | + camera.add(cameraLabel = new JLabel("GlobalLight")); // , aConstraints); |
---|
| 1610 | + cameraLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1611 | + camera.add(cameraField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1612 | + globalSection.add(camera); |
---|
1664 | 1613 | |
---|
1665 | | - ctrlPanel.add(backlitLabel = new JLabel("Backlit"), aConstraints); |
---|
1666 | | - backlitLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1667 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1668 | | - aConstraints.gridx += 1; |
---|
1669 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1670 | | - ctrlPanel.add(backlitField = new NumberSlider(0.001, 50, -1), aConstraints); |
---|
1671 | | - aConstraints.gridx = 0; |
---|
1672 | | - aConstraints.gridy += 1; |
---|
1673 | | - aConstraints.gridwidth = 1; |
---|
| 1614 | + cGridBag ambient = new cGridBag(); |
---|
| 1615 | + ambient.add(ambientLabel = new JLabel("Ambient")); // , aConstraints); |
---|
| 1616 | + ambientLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1617 | + ambient.add(ambientField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1618 | + globalSection.add(ambient); |
---|
1674 | 1619 | |
---|
1675 | | - ctrlPanel.add(opacityLabel = new JLabel("Opacity"), aConstraints); |
---|
1676 | | - opacityLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1677 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1678 | | - aConstraints.gridx += 1; |
---|
1679 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1680 | | - ctrlPanel.add(opacityField = new NumberSlider(0.001, 1, -0.1), aConstraints); |
---|
1681 | | - aConstraints.gridx = 0; |
---|
1682 | | - aConstraints.gridy += 1; |
---|
1683 | | - aConstraints.gridwidth = 1; |
---|
1684 | | - aConstraints.weighty = 0; |
---|
| 1620 | + cGridBag backlit = new cGridBag(); |
---|
| 1621 | + backlit.add(backlitLabel = new JLabel("Backlit")); // , aConstraints); |
---|
| 1622 | + backlitLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1623 | + backlit.add(backlitField = new cNumberSlider(this, 0.001, 50, -1)); // , aConstraints); |
---|
| 1624 | + globalSection.add(backlit); |
---|
1685 | 1625 | |
---|
1686 | | - ctrlPanel.add(bumpLabel = new JLabel("Bump"), aConstraints); |
---|
1687 | | - bumpLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1688 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1689 | | - aConstraints.gridx += 1; |
---|
1690 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1691 | | - ctrlPanel.add(bumpField = new NumberSlider(0.0, 2), aConstraints); |
---|
1692 | | - aConstraints.gridx = 0; |
---|
1693 | | - aConstraints.gridy += 1; |
---|
1694 | | - aConstraints.gridwidth = 1; |
---|
| 1626 | + cGridBag opacity = new cGridBag(); |
---|
| 1627 | + opacity.add(opacityLabel = new JLabel("Opacity")); // , aConstraints); |
---|
| 1628 | + opacityLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1629 | + opacity.add(opacityField = new cNumberSlider(this, 0.001, 1, -0.5)); // , aConstraints); |
---|
| 1630 | + globalSection.add(opacity); |
---|
1695 | 1631 | |
---|
1696 | | - ctrlPanel.add(noiseLabel = new JLabel("Noise"), aConstraints); |
---|
1697 | | - noiseLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1698 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1699 | | - aConstraints.gridx += 1; |
---|
1700 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1701 | | - ctrlPanel.add(noiseField = new NumberSlider(0.0, 1/*5*/), aConstraints); |
---|
1702 | | - aConstraints.gridx = 0; |
---|
1703 | | - aConstraints.gridy += 1; |
---|
1704 | | - aConstraints.gridwidth = 1; |
---|
| 1632 | + panel.add(new JSeparator()); |
---|
| 1633 | + |
---|
| 1634 | + panel.add(globalSection); |
---|
| 1635 | + |
---|
| 1636 | + //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints); |
---|
| 1637 | + |
---|
| 1638 | + cGridBag textureSection = new cGridBag().setVertical(true); |
---|
1705 | 1639 | |
---|
1706 | | - ctrlPanel.add(powerLabel = new JLabel("Turbulance"), aConstraints); |
---|
1707 | | - powerLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1708 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1709 | | - aConstraints.gridx += 1; |
---|
1710 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1711 | | - ctrlPanel.add(powerField = new NumberSlider(0.0, 5), aConstraints); |
---|
1712 | | - aConstraints.gridx = 0; |
---|
1713 | | - aConstraints.gridy += 1; |
---|
1714 | | - aConstraints.gridwidth = 1; |
---|
| 1640 | + cGridBag bump = new cGridBag(); |
---|
| 1641 | + bump.add(bumpLabel = new JLabel("Bump")); // , aConstraints); |
---|
| 1642 | + bumpLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1643 | + bump.add(bumpField = new cNumberSlider(this, 0.0, 2)); // , aConstraints); |
---|
| 1644 | + textureSection.add(bump); |
---|
1715 | 1645 | |
---|
1716 | | - ctrlPanel.add(borderfadeLabel = new JLabel("Borderfade"), aConstraints); |
---|
1717 | | - borderfadeLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1718 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1719 | | - aConstraints.gridx += 1; |
---|
1720 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1721 | | - ctrlPanel.add(borderfadeField = new NumberSlider(0.0, 2), aConstraints); |
---|
1722 | | - aConstraints.gridx = 0; |
---|
1723 | | - aConstraints.gridy += 1; |
---|
1724 | | - aConstraints.gridwidth = 1; |
---|
| 1646 | + cGridBag noise = new cGridBag(); |
---|
| 1647 | + noise.add(noiseLabel = new JLabel("Noise")); // , aConstraints); |
---|
| 1648 | + noiseLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1649 | + noise.add(noiseField = new cNumberSlider(this, 0.0, 1/*5*/)); // , aConstraints); |
---|
| 1650 | + textureSection.add(noise); |
---|
1725 | 1651 | |
---|
1726 | | - ctrlPanel.add(fogLabel = new JLabel("Punch"), aConstraints); |
---|
1727 | | - fogLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1728 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1729 | | - aConstraints.gridx += 1; |
---|
1730 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1731 | | - ctrlPanel.add(fogField = new NumberSlider(0.0, 20), aConstraints); |
---|
1732 | | - aConstraints.gridx = 0; |
---|
1733 | | - aConstraints.gridy += 1; |
---|
1734 | | - aConstraints.gridwidth = 1; |
---|
| 1652 | + cGridBag power = new cGridBag(); |
---|
| 1653 | + power.add(powerLabel = new JLabel("Turbulance")); // , aConstraints); |
---|
| 1654 | + powerLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1655 | + power.add(powerField = new cNumberSlider(this, 0.0, 5)); // , aConstraints); |
---|
| 1656 | + textureSection.add(power); |
---|
1735 | 1657 | |
---|
1736 | | - ctrlPanel.add(opacityPowerLabel = new JLabel("Halo"), aConstraints); |
---|
1737 | | - opacityPowerLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
1738 | | - aConstraints.fill = GridBagConstraints.HORIZONTAL; |
---|
1739 | | - aConstraints.gridx += 1; |
---|
1740 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; |
---|
1741 | | - ctrlPanel.add(opacityPowerField = new NumberSlider(0.0, 10 /*10 dec 2013*/), aConstraints); |
---|
1742 | | - aConstraints.gridx = 0; |
---|
1743 | | - aConstraints.gridy += 1; |
---|
1744 | | - aConstraints.gridwidth = 1; |
---|
| 1658 | + cGridBag borderfade = new cGridBag(); |
---|
| 1659 | + borderfade.add(borderfadeLabel = new JLabel("Borderfade")); // , aConstraints); |
---|
| 1660 | + borderfadeLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1661 | + borderfade.add(borderfadeField = new cNumberSlider(this, 0.0, 2)); // , aConstraints); |
---|
| 1662 | + textureSection.add(borderfade); |
---|
1745 | 1663 | |
---|
1746 | | - //aConstraints.weighty = 1; |
---|
1747 | | - aConstraints.gridwidth = ObjEditor.GRIDWIDTH; // 100; |
---|
1748 | | - //aConstraints.gridx += 1; |
---|
1749 | | - ctrlPanel.add(new JLabel("----------------------------------"), aConstraints); |
---|
1750 | | - aConstraints.weighty = 0; |
---|
| 1664 | + cGridBag fog = new cGridBag(); |
---|
| 1665 | + fog.add(fogLabel = new JLabel("Punch")); // , aConstraints); |
---|
| 1666 | + fogLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1667 | + fog.add(fogField = new cNumberSlider(this, 0.0, 20)); // , aConstraints); |
---|
| 1668 | + textureSection.add(fog); |
---|
1751 | 1669 | |
---|
1752 | | - aConstraints.gridx = 0; |
---|
1753 | | - aConstraints.gridy = 0; |
---|
1754 | | - aConstraints.gridwidth = 1; |
---|
| 1670 | + cGridBag opacityPower = new cGridBag(); |
---|
| 1671 | + opacityPower.add(opacityPowerLabel = new JLabel("Halo")); // , aConstraints); |
---|
| 1672 | + opacityPowerLabel.setHorizontalAlignment(SwingConstants.TRAILING); |
---|
| 1673 | + opacityPower.add(opacityPowerField = new cNumberSlider(this, 0.0, 10 /*10 dec 2013*/)); // , aConstraints); |
---|
| 1674 | + textureSection.add(opacityPower); |
---|
| 1675 | + |
---|
| 1676 | + panel.add(new JSeparator()); |
---|
| 1677 | + |
---|
| 1678 | + panel.add(textureSection); |
---|
| 1679 | + |
---|
| 1680 | + //ctrlPanel.add(new JLabel("----------------------------------")); // , aConstraints); |
---|
1755 | 1681 | |
---|
1756 | 1682 | SetMaterial(copy); // .GetMaterial()); |
---|
1757 | 1683 | |
---|
1758 | | - colorField.addChangeListener(this); |
---|
1759 | | - modulationField.addChangeListener(this); |
---|
| 1684 | + //colorField.addChangeListener(this); |
---|
| 1685 | +// modulationField.addChangeListener(this); |
---|
1760 | 1686 | metalnessField.addChangeListener(this); |
---|
1761 | 1687 | diffuseField.addChangeListener(this); |
---|
1762 | 1688 | specularField.addChangeListener(this); |
---|
.. | .. |
---|
2568 | 2494 | } |
---|
2569 | 2495 | if (input == null) |
---|
2570 | 2496 | { |
---|
| 2497 | + new Exception().printStackTrace(); |
---|
2571 | 2498 | System.exit(0); |
---|
2572 | 2499 | } |
---|
2573 | 2500 | |
---|
.. | .. |
---|
2966 | 2893 | return; |
---|
2967 | 2894 | } else if (event.getSource() == toggleTimelineItem) |
---|
2968 | 2895 | { |
---|
2969 | | - copy.timeline ^= true; |
---|
| 2896 | + timeline ^= true; |
---|
2970 | 2897 | |
---|
2971 | | - if (copy.timeline) |
---|
| 2898 | + if (timeline) |
---|
2972 | 2899 | { |
---|
2973 | 2900 | centralPanel.remove(cameraView); |
---|
2974 | | - centralPanel.add(timelinePanel); |
---|
| 2901 | + cameraPanel.add(cameraView); |
---|
| 2902 | + centralPanel.add(cameraPanel); |
---|
2975 | 2903 | frame.setJMenuBar(timelineMenubar); |
---|
| 2904 | + wasFullScreen = CameraPane.FULLSCREEN; |
---|
| 2905 | + if (!CameraPane.FULLSCREEN) |
---|
| 2906 | + ToggleFullScreen(); |
---|
| 2907 | + toggleFullScreenItem.setEnabled(false); |
---|
2976 | 2908 | } |
---|
2977 | 2909 | else |
---|
2978 | 2910 | { |
---|
2979 | | - centralPanel.remove(timelinePanel); |
---|
| 2911 | + centralPanel.remove(cameraPanel); |
---|
2980 | 2912 | centralPanel.add(cameraView); |
---|
2981 | 2913 | frame.setJMenuBar(null); |
---|
| 2914 | + if (!wasFullScreen) |
---|
| 2915 | + ToggleFullScreen(); |
---|
| 2916 | + toggleFullScreenItem.setEnabled(true); |
---|
2982 | 2917 | } |
---|
2983 | 2918 | |
---|
2984 | 2919 | frame.validate(); |
---|
2985 | 2920 | return; |
---|
2986 | 2921 | } else if (event.getSource() == toggleFullScreenItem) |
---|
2987 | 2922 | { |
---|
2988 | | - if (CameraPane.FULLSCREEN) |
---|
2989 | | - { |
---|
2990 | | - frame.getContentPane().remove(/*"Center",*/bigThree); |
---|
2991 | | - framePanel.add(bigThree); |
---|
2992 | | - frame.getContentPane().add(/*"Center",*/framePanel); |
---|
2993 | | - } else |
---|
2994 | | - { |
---|
2995 | | - frame.getContentPane().remove(/*"Center",*/framePanel); |
---|
2996 | | - frame.getContentPane().add(/*"Center",*/bigThree); |
---|
2997 | | - } |
---|
| 2923 | + ToggleFullScreen(); |
---|
2998 | 2924 | frame.validate(); |
---|
2999 | | - cameraView.ToggleFullScreen(); |
---|
3000 | 2925 | |
---|
3001 | 2926 | return; |
---|
3002 | 2927 | } else if (event.getSource() == toggleRandomItem) |
---|
.. | .. |
---|
3106 | 3031 | objEditor.refreshContents(); |
---|
3107 | 3032 | } else if (event.getSource() == stepItem) |
---|
3108 | 3033 | { |
---|
3109 | | - cameraView.ONESTEP = true; |
---|
| 3034 | + //cameraView.ONESTEP = true; |
---|
| 3035 | + Globals.ONESTEP = true; |
---|
3110 | 3036 | cameraView.repaint(); |
---|
3111 | 3037 | return; |
---|
3112 | 3038 | } else if (event.getSource() == stepButton) |
---|
.. | .. |
---|
3263 | 3189 | |
---|
3264 | 3190 | void ToggleAnimation() |
---|
3265 | 3191 | { |
---|
3266 | | - if (!CameraPane.ANIMATION) |
---|
| 3192 | + if (!Globals.ANIMATION) |
---|
3267 | 3193 | { |
---|
3268 | 3194 | FileDialog browser = new FileDialog(frame, "Save Animation As...", FileDialog.SAVE); |
---|
3269 | 3195 | browser.show(); |
---|
3270 | 3196 | String filename = browser.getFile(); |
---|
3271 | 3197 | if (filename != null && filename.length() > 0) |
---|
3272 | 3198 | { |
---|
3273 | | - CameraPane.filename = browser.getDirectory() + filename; |
---|
| 3199 | + Globals.filename = browser.getDirectory() + filename; |
---|
3274 | 3200 | //CameraPane.framecount = 0; |
---|
3275 | | - CameraPane.imagecount = 0; |
---|
| 3201 | + Globals.imagecount = 0; |
---|
3276 | 3202 | |
---|
3277 | | - CameraPane.ANIMATION ^= true; |
---|
| 3203 | + Globals.ANIMATION ^= true; |
---|
3278 | 3204 | |
---|
3279 | 3205 | GrafreeD.wav.cursor = 0; |
---|
3280 | 3206 | GrafreeD.wav.loop = 0; |
---|
3281 | 3207 | } |
---|
3282 | 3208 | } else |
---|
3283 | 3209 | { |
---|
3284 | | - CameraPane.ANIMATION ^= true; |
---|
| 3210 | + Globals.ANIMATION ^= true; |
---|
3285 | 3211 | } |
---|
3286 | 3212 | } |
---|
3287 | 3213 | |
---|
.. | .. |
---|
3298 | 3224 | callee.refreshContents(); |
---|
3299 | 3225 | } else |
---|
3300 | 3226 | { |
---|
| 3227 | + new Exception().printStackTrace(); |
---|
3301 | 3228 | System.exit(0); |
---|
3302 | 3229 | } |
---|
3303 | 3230 | } |
---|
.. | .. |
---|
3460 | 3387 | current.fakedepth = (float) fakedepthField.getFloat(); |
---|
3461 | 3388 | current.shadowbias = (float) shadowbiasField.getFloat(); |
---|
3462 | 3389 | |
---|
3463 | | - if (!NumberSlider.frozen) |
---|
| 3390 | + if (!cNumberSlider.frozen) |
---|
3464 | 3391 | { |
---|
3465 | 3392 | //System.out.println("Propagate = " + propagate); |
---|
3466 | 3393 | copy.UpdateMaterial(anchor, current, propagate); |
---|
.. | .. |
---|
3508 | 3435 | || e.getSource() == apertureField |
---|
3509 | 3436 | || e.getSource() == shadowblurField) |
---|
3510 | 3437 | { |
---|
| 3438 | + new Exception().printStackTrace(); |
---|
3511 | 3439 | System.exit(0); |
---|
3512 | 3440 | cameraView.options1[0] = (float) focusField.getFloat() * 10; |
---|
3513 | 3441 | cameraView.options1[1] = (float) apertureField.getFloat() / 1000; |
---|
.. | .. |
---|
3534 | 3462 | //System.out.println("PARENT = " + parent); |
---|
3535 | 3463 | //if (parent != null) |
---|
3536 | 3464 | // parent.applySelf(); |
---|
3537 | | - refreshContents(); |
---|
| 3465 | + if (e.getSource() == normalpushField) |
---|
| 3466 | + { |
---|
| 3467 | + objEditor.refreshContents(); |
---|
| 3468 | + //Refresh(); |
---|
| 3469 | + } |
---|
| 3470 | + else |
---|
| 3471 | + refreshContents(); |
---|
3538 | 3472 | // ??? client.refreshEditWindow(); |
---|
3539 | 3473 | } |
---|
3540 | 3474 | //else |
---|
.. | .. |
---|
3546 | 3480 | //group.name = nameField.getText(); |
---|
3547 | 3481 | //objEditor.applySelf(); |
---|
3548 | 3482 | |
---|
3549 | | - assert (objEditor == this); |
---|
| 3483 | + // OCT2018: assert (objEditor == this); |
---|
3550 | 3484 | if (copy.selection == null || copy.selection.size() == 0) |
---|
3551 | 3485 | //super.applySelf() |
---|
3552 | 3486 | ; else |
---|
.. | .. |
---|
3570 | 3504 | objEditor.copy = keep; |
---|
3571 | 3505 | } |
---|
3572 | 3506 | } |
---|
| 3507 | + |
---|
| 3508 | + if (normalpushField != null) |
---|
| 3509 | + copy.NORMALPUSH = (float)normalpushField.getFloat()/1000; |
---|
3573 | 3510 | } |
---|
3574 | 3511 | |
---|
3575 | 3512 | void SnapObject() |
---|
3576 | 3513 | { |
---|
3577 | | - Object3D obj = (Object3D)copy.selection.elementAt(0); |
---|
3578 | | - SnapObject(obj); |
---|
| 3514 | + if (copy.selection.size() > 0) |
---|
| 3515 | + { |
---|
| 3516 | + Object3D obj = (Object3D)copy.selection.elementAt(0); |
---|
| 3517 | + SnapObject(obj); |
---|
| 3518 | + } |
---|
3579 | 3519 | } |
---|
3580 | 3520 | |
---|
3581 | 3521 | void SnapObject(Object3D obj) |
---|
.. | .. |
---|
3821 | 3761 | |
---|
3822 | 3762 | radioPanel.revalidate(); |
---|
3823 | 3763 | radioPanel.repaint(); |
---|
3824 | | - ctrlPanel.revalidate(); // ? new |
---|
| 3764 | + ctrlPanel.validate(); // ? new |
---|
3825 | 3765 | ctrlPanel.repaint(); |
---|
3826 | 3766 | } |
---|
3827 | 3767 | } |
---|
.. | .. |
---|
4467 | 4407 | //MenuItem normalLensItem; |
---|
4468 | 4408 | MenuItem editCameraItem; |
---|
4469 | 4409 | MenuItem revertCameraItem; |
---|
4470 | | - CheckboxMenuItem toggleLiveItem; |
---|
4471 | 4410 | MenuItem stepItem; |
---|
| 4411 | + CheckboxMenuItem toggleLiveItem; |
---|
4472 | 4412 | CheckboxMenuItem toggleFullScreenItem; |
---|
4473 | 4413 | CheckboxMenuItem toggleTimelineItem; |
---|
4474 | 4414 | CheckboxMenuItem toggleRenderItem; |
---|
.. | .. |
---|
4488 | 4428 | JPanel treePanel; |
---|
4489 | 4429 | JPanel radioPanel; |
---|
4490 | 4430 | ButtonGroup buttonGroup; |
---|
4491 | | - JPanel ctrlPanel; |
---|
4492 | | - JPanel materialPanel; |
---|
| 4431 | + cGridBag ctrlPanel; |
---|
| 4432 | + cGridBag materialPanel; |
---|
4493 | 4433 | JScrollPane infoPanel; |
---|
4494 | | - JPanel optionsPanel; |
---|
| 4434 | + cGridBag optionsPanel; |
---|
4495 | 4435 | JTabbedPane objectPanel; |
---|
4496 | | - JPanel XYZPanel; |
---|
| 4436 | + cGridBag XYZPanel; |
---|
4497 | 4437 | JSplitPane gridPanel; |
---|
4498 | 4438 | JSplitPane bigPanel; |
---|
4499 | | - JPanel bigThree; |
---|
4500 | | - JTabbedPane scenePanel; |
---|
4501 | | - JPanel centralPanel; |
---|
| 4439 | + cGridBag bigThree; |
---|
| 4440 | + cGridBag scenePanel; |
---|
| 4441 | + cGridBag centralPanel; |
---|
| 4442 | + JSplitPane cameraPanel; |
---|
4502 | 4443 | JPanel timelinePanel; |
---|
4503 | 4444 | JMenuBar timelineMenubar; |
---|
4504 | 4445 | JSplitPane framePanel; |
---|
.. | .. |
---|
4550 | 4491 | // MATERIAL |
---|
4551 | 4492 | JLabel materialLabel; |
---|
4552 | 4493 | JLabel colorLabel; |
---|
4553 | | - NumberSlider colorField; |
---|
| 4494 | + cNumberSlider colorField; |
---|
4554 | 4495 | JLabel modulationLabel; |
---|
4555 | | - NumberSlider modulationField; |
---|
| 4496 | + cNumberSlider modulationField; |
---|
4556 | 4497 | JLabel metalnessLabel; |
---|
4557 | | - NumberSlider metalnessField; |
---|
| 4498 | + cNumberSlider metalnessField; |
---|
4558 | 4499 | JLabel diffuseLabel; |
---|
4559 | | - NumberSlider diffuseField; |
---|
| 4500 | + cNumberSlider diffuseField; |
---|
4560 | 4501 | JLabel specularLabel; |
---|
4561 | | - NumberSlider specularField; |
---|
| 4502 | + cNumberSlider specularField; |
---|
4562 | 4503 | JLabel shininessLabel; |
---|
4563 | | - NumberSlider shininessField; |
---|
| 4504 | + cNumberSlider shininessField; |
---|
4564 | 4505 | JLabel shiftLabel; |
---|
4565 | | - NumberSlider shiftField; |
---|
| 4506 | + cNumberSlider shiftField; |
---|
4566 | 4507 | JLabel ambientLabel; |
---|
4567 | | - NumberSlider ambientField; |
---|
| 4508 | + cNumberSlider ambientField; |
---|
4568 | 4509 | JLabel lightareaLabel; |
---|
4569 | | - NumberSlider lightareaField; |
---|
| 4510 | + cNumberSlider lightareaField; |
---|
4570 | 4511 | JLabel diffusenessLabel; |
---|
4571 | | - NumberSlider diffusenessField; |
---|
| 4512 | + cNumberSlider diffusenessField; |
---|
4572 | 4513 | JLabel velvetLabel; |
---|
4573 | | - NumberSlider velvetField; |
---|
| 4514 | + cNumberSlider velvetField; |
---|
4574 | 4515 | JLabel sheenLabel; |
---|
4575 | | - NumberSlider sheenField; |
---|
| 4516 | + cNumberSlider sheenField; |
---|
4576 | 4517 | JLabel subsurfaceLabel; |
---|
4577 | | - NumberSlider subsurfaceField; |
---|
| 4518 | + cNumberSlider subsurfaceField; |
---|
4578 | 4519 | //JLabel bumpLabel; |
---|
4579 | 4520 | //NumberSlider bumpField; |
---|
4580 | 4521 | JLabel backlitLabel; |
---|
4581 | | - NumberSlider backlitField; |
---|
| 4522 | + cNumberSlider backlitField; |
---|
4582 | 4523 | JLabel anisoLabel; |
---|
4583 | | - NumberSlider anisoField; |
---|
| 4524 | + cNumberSlider anisoField; |
---|
4584 | 4525 | JLabel anisoVLabel; |
---|
4585 | | - NumberSlider anisoVField; |
---|
| 4526 | + cNumberSlider anisoVField; |
---|
4586 | 4527 | JLabel cameraLabel; |
---|
4587 | | - NumberSlider cameraField; |
---|
| 4528 | + cNumberSlider cameraField; |
---|
4588 | 4529 | JLabel selfshadowLabel; |
---|
4589 | | - NumberSlider selfshadowField; |
---|
| 4530 | + cNumberSlider selfshadowField; |
---|
4590 | 4531 | JLabel shadowLabel; |
---|
4591 | | - NumberSlider shadowField; |
---|
| 4532 | + cNumberSlider shadowField; |
---|
4592 | 4533 | JLabel textureLabel; |
---|
4593 | | - NumberSlider textureField; |
---|
| 4534 | + cNumberSlider textureField; |
---|
4594 | 4535 | JLabel opacityLabel; |
---|
4595 | | - NumberSlider opacityField; |
---|
| 4536 | + cNumberSlider opacityField; |
---|
4596 | 4537 | JLabel fakedepthLabel; |
---|
4597 | | - NumberSlider fakedepthField; |
---|
| 4538 | + cNumberSlider fakedepthField; |
---|
4598 | 4539 | JLabel shadowbiasLabel; |
---|
4599 | | - NumberSlider shadowbiasField; |
---|
| 4540 | + cNumberSlider shadowbiasField; |
---|
4600 | 4541 | JLabel bumpLabel; |
---|
4601 | | - NumberSlider bumpField; |
---|
| 4542 | + cNumberSlider bumpField; |
---|
4602 | 4543 | JLabel noiseLabel; |
---|
4603 | | - NumberSlider noiseField; |
---|
| 4544 | + cNumberSlider noiseField; |
---|
4604 | 4545 | JLabel powerLabel; |
---|
4605 | | - NumberSlider powerField; |
---|
| 4546 | + cNumberSlider powerField; |
---|
4606 | 4547 | JLabel borderfadeLabel; |
---|
4607 | | - NumberSlider borderfadeField; |
---|
| 4548 | + cNumberSlider borderfadeField; |
---|
4608 | 4549 | JLabel fogLabel; |
---|
4609 | | - NumberSlider fogField; |
---|
| 4550 | + cNumberSlider fogField; |
---|
4610 | 4551 | JLabel opacityPowerLabel; |
---|
4611 | | - NumberSlider opacityPowerField; |
---|
| 4552 | + cNumberSlider opacityPowerField; |
---|
4612 | 4553 | JTree jTree; |
---|
4613 | 4554 | //ObjectUI parent; |
---|
| 4555 | + |
---|
| 4556 | + cNumberSlider normalpushField; |
---|
4614 | 4557 | } |
---|