From 13e9febe94aaeebad9c97f6d3e2aa4d73b2495c8 Mon Sep 17 00:00:00 2001 From: Normand Briere <nbriere@noware.ca> Date: Mon, 17 Jun 2019 18:49:45 -0400 Subject: [PATCH] Fix refresh info. --- GroupEditor.java | 39 +++++++++++++++++++++++++++++++-------- 1 files changed, 31 insertions(+), 8 deletions(-) diff --git a/GroupEditor.java b/GroupEditor.java index 43af894..4f34e39 100644 --- a/GroupEditor.java +++ b/GroupEditor.java @@ -871,6 +871,7 @@ } else if(e.getSource() == liveCB) { cameraView.ToggleLive(); + refreshContents(false); } else if(e.getSource() == supportCB) { @@ -1278,7 +1279,7 @@ memoryItem.addActionListener(this); menu.add(analyzeItem = new MenuItem("Analyze")); analyzeItem.addActionListener(this); - menu.add(dumpItem = new MenuItem("Dump")); + menu.add(dumpItem = new MenuItem("Print")); dumpItem.addActionListener(this); // menu.add(pathItem = new MenuItem("From-to path")); // pathItem.addActionListener(this); @@ -2542,7 +2543,7 @@ } else if (source == genNormalsMESHItem) { - GenNormals(true); // TODO + GenNormalsMESH(); } else if (source == genNormalsORGANItem) { @@ -3515,6 +3516,13 @@ refreshContents(); } + void GenNormalsMESH() + { + group.GenNormalsMeshS(); + + refreshContents(); + } + void GenNormalsMINE() { group.selection.GenNormalsMINE(); @@ -4313,7 +4321,6 @@ //case 702: // Event.LIST_DESELECT group.deselectAll(); TreePath tps[] = objEditor.jTree.getSelectionPaths(); - objEditor.ClearInfo(); // .GetMaterial()); if (tps != null) { for (int i=0; i < tps.length; i++) @@ -4322,10 +4329,8 @@ //if (child.parent != null) //child.parent.addSelectee(child); + objEditor.SetMaterial(child); group.addSelectee(child); - objEditor.SetMaterial(child); // .GetMaterial()); - objEditor.AddInfo(child, this, true); // .GetMaterial()); - System.err.println("info : " + child.GetPath()); } } // else @@ -4335,8 +4340,6 @@ // System.err.println("info : " + group.GetPath()); // } - objEditor.SetText(); // jan 2014 - if (flashIt && !Globals.isLIVE() && tps != null && tps.length > 0 && !(tps[0].getLastPathComponent() instanceof Camera)) CameraPane.flash = true; @@ -4360,6 +4363,26 @@ freezemodel = false; } + + void refreshContents(boolean cp) + { + if (!Globals.MOUSEDRAGGED) + { + objEditor.ClearInfo(); // .GetMaterial()); + + for (int i=0; i < group.selection.Size(); i++) + { + Object3D child = (Object3D) group.selection.get(i); + + objEditor.AddInfo(child, this, true); + System.err.println("info : " + child.GetPath()); + } + + objEditor.SetText(); // jan 2014 + } + + super.refreshContents(cp); + } void linkSomething(Object3D thing) { -- Gitblit v1.6.2