Normand Briere
2019-06-16 7b6b5ba546450e71ecc812356952b594acc5add5
Fix shadow touched.
3 files modified
21 ■■■■ changed files
Globals.java 2 ●●●●● patch | view | raw | blame | history
ObjEditor.java 15 ●●●● patch | view | raw | blame | history
Object3D.java 4 ●●● patch | view | raw | blame | history
Globals.java
....@@ -8,6 +8,8 @@
88 private static boolean LIVE = false;
99 public static boolean RENDERSHADOW = true;
1010
11
+ public static boolean MOUSEDRAGGED = false;
12
+
1113 // Hold on calculation when moving camera
1214 public static boolean FREEZEONMOVE = false; // true;
1315
ObjEditor.java
....@@ -419,10 +419,10 @@
419419 e.printStackTrace();
420420 }
421421
422
- String selection = infoarea.getText();
423
- java.awt.datatransfer.StringSelection data = new java.awt.datatransfer.StringSelection(selection);
424
- java.awt.datatransfer.Clipboard clipboard =
425
- Toolkit.getDefaultToolkit().getSystemClipboard();
422
+// String selection = infoarea.getText();
423
+// java.awt.datatransfer.StringSelection data = new java.awt.datatransfer.StringSelection(selection);
424
+// java.awt.datatransfer.Clipboard clipboard =
425
+// Toolkit.getDefaultToolkit().getSystemClipboard();
426426 //clipboard.setContents(data, data);
427427 }
428428
....@@ -4295,6 +4295,7 @@
42954295
42964296 try
42974297 {
4298
+ // Try compressed version first.
42984299 java.io.FileInputStream istream = new java.io.FileInputStream(fullname);
42994300 java.util.zip.GZIPInputStream zstream = new java.util.zip.GZIPInputStream(istream);
43004301 java.io.ObjectInputStream p = new java.io.ObjectInputStream(zstream);
....@@ -4364,6 +4365,12 @@
43644365
43654366 void LoadIt(Object obj)
43664367 {
4368
+ if (obj == null)
4369
+ {
4370
+ // Invalid file
4371
+ return;
4372
+ }
4373
+
43674374 System.out.println("Loaded " + obj);
43684375 //new Exception().printStackTrace();
43694376 Object3D readobj = (Object3D) obj;
Object3D.java
....@@ -5673,10 +5673,12 @@
56735673 boolean selectmode = display.DrawMode() == display.SELECTION || display.IsDebugSelection();
56745674
56755675 if (!selectmode && //display.DrawMode() != display.SELECTION &&
5676
- (touched || (bRep != null && bRep.displaylist <= 0)))
5676
+ //(touched || (bRep != null && bRep.displaylist <= 0)))
5677
+ (Globals.isLIVE() || touched && (bRep != null && bRep.displaylist <= 0)))
56775678 {
56785679 Globals.lighttouched = true;
56795680 } // all panes...
5681
+
56805682 //if (usecalllists && display.DrawMode() != display.SELECTION && display.DrawMode() != display.SHADOW &&
56815683 if (bRep != null && usecalllists && !selectmode && // june 2013 display.DrawMode() != display.SHADOW &&
56825684 (touched || (bRep != null && bRep.displaylist <= 0)))