Normand Briere
2019-07-01 6600d22461ccc1cb602f238a9ffa83cf07dd830e
Object3D.java
....@@ -181,7 +181,7 @@
181181 return;
182182 }
183183
184
- Object3D o = new Object3D();
184
+ Object3D o = new Object3D("copy of " + this.name);
185185
186186 hashtable.put(GetUUID(), o);
187187
....@@ -219,16 +219,23 @@
219219 if (!hashtable.containsKey(GetUUID()))
220220 return;
221221
222
+ if (blockloop)
223
+ return;
224
+
225
+ blockloop = true;
226
+
222227 Object3D o = hashtable.get(GetUUID());
223228
224229 RestoreBigData(o);
225230
226
- hashtable.remove(GetUUID());
231
+ //hashtable.remove(GetUUID());
227232
228233 for (int i=0; i<Size(); i++)
229234 {
230235 get(i).RestoreBigData(hashtable);
231236 }
237
+
238
+ blockloop = false;
232239 }
233240
234241 void RestoreBigData(Object3D o)
....@@ -2433,6 +2440,14 @@
24332440 {
24342441 editWindow.refreshContents();
24352442 }
2443
+ else
2444
+ {
2445
+ if (manipWindow != null)
2446
+ {
2447
+ manipWindow.refreshContents();
2448
+ }
2449
+ }
2450
+
24362451 //if (parent != null)
24372452 //parent.refreshEditWindow();
24382453 }
....@@ -4963,6 +4978,14 @@
49634978 }
49644979 }
49654980
4981
+ ObjEditor GetWindow()
4982
+ {
4983
+ if (editWindow != null)
4984
+ return editWindow;
4985
+
4986
+ return manipWindow;
4987
+ }
4988
+
49664989 cTreePath Select(int indexcount, boolean deselect)
49674990 {
49684991 if (hide || dontselect)
....@@ -4999,10 +5022,11 @@
49995022 if (leaf != null)
50005023 {
50015024 cTreePath tp = new cTreePath(this, leaf);
5002
- if (editWindow != null)
5025
+ ObjEditor window = GetWindow();
5026
+ if (window != null)
50035027 {
50045028 //System.out.println("editWindow = " + editWindow + " vs " + this);
5005
- editWindow.Select(tp, deselect, true);
5029
+ window.Select(tp, deselect, true);
50065030 }
50075031
50085032 return tp;
....@@ -5019,6 +5043,7 @@
50195043
50205044 if (child == null)
50215045 continue;
5046
+
50225047 if (child.HasTransparency() && child.size() != 0)
50235048 {
50245049 cTreePath leaf = child.Select(indexcount, deselect);
....@@ -5028,9 +5053,10 @@
50285053 if (leaf != null)
50295054 {
50305055 cTreePath tp = new cTreePath(this, leaf);
5031
- if (editWindow != null)
5056
+ ObjEditor window = GetWindow();
5057
+ if (window != null)
50325058 {
5033
- editWindow.Select(tp, deselect, true);
5059
+ window.Select(tp, deselect, true);
50345060 }
50355061
50365062 return tp;
....@@ -5772,7 +5798,7 @@
57725798
57735799 if (!selectmode && //display.DrawMode() != display.SELECTION &&
57745800 //(touched || (bRep != null && bRep.displaylist <= 0)))
5775
- (Globals.isLIVE() && Globals.COMPUTESHADOWWHENLIVE || touched && (bRep != null && bRep.displaylist <= 0)))
5801
+ (Globals.isLIVE() && Globals.COMPUTESHADOWWHENLIVE || touched && Globals.COMPUTESHADOWWHENLIVE)) // || (bRep != null && bRep.displaylist <= 0)))
57765802 {
57775803 Globals.lighttouched = true;
57785804 } // all panes...
....@@ -5904,6 +5930,7 @@
59045930 if (GetBRep() != null)
59055931 {
59065932 display.NextIndex();
5933
+
59075934 // vertex color conflict : gl.glCallList(list);
59085935 DrawNode(display, root, selected);
59095936 if (this instanceof BezierPatch)
....@@ -7967,6 +7994,10 @@
79677994 }
79687995
79697996 transient ObjEditor editWindow;
7997
+ transient ObjEditor manipWindow;
7998
+
7999
+ transient boolean pinned;
8000
+
79708001 transient ObjectUI objectUI;
79718002 public static int povDepth = 0;
79728003 private static cVector tbMin = new cVector();