From 81b8ed4a47ae6716c1d38ffe754ff31b5b996289 Mon Sep 17 00:00:00 2001 From: "nor..67" Date: Wed, 13 Feb 2013 15:44:07 +0000 Subject: [PATCH] SDK: - remove unused methods in SceneComposer git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10396 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- .../SceneComposerTopComponent.java | 14 +-- .../scenecomposer/SceneEditorController.java | 94 +++++++++---------- 2 files changed, 54 insertions(+), 54 deletions(-) diff --git a/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneComposerTopComponent.java b/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneComposerTopComponent.java index 50fcc2d23..3fbc13cdc 100644 --- a/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneComposerTopComponent.java +++ b/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneComposerTopComponent.java @@ -899,13 +899,13 @@ private void jToggleSelectGeomActionPerformed(java.awt.event.ActionEvent evt) {/ SceneApplication.getApplication().openScene(request); } - public void addModel(Spatial model) { - if (editorController != null) { - editorController.addModel(model, toolController.getCursorLocation()); - } else { - displayInfo("No scene opened!"); - } - } +// public void addModel(Spatial model) { +// if (editorController != null) { +// editorController.addModel(model, toolController.getCursorLocation()); +// } else { +// displayInfo("No scene opened!"); +// } +// } public void addModel(SpatialAssetDataObject model) { if (editorController != null) { diff --git a/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneEditorController.java b/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneEditorController.java index dfbad184c..3e9d9cd96 100644 --- a/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneEditorController.java +++ b/sdk/jme3-scenecomposer/src/com/jme3/gde/scenecomposer/SceneEditorController.java @@ -644,53 +644,53 @@ public class SceneEditorController implements PropertyChangeListener, NodeListen } - public void addModel(final Spatial file) { - addModel(file, null); - } - - public void addModel(final Spatial file, final Vector3f location) { - if (selectedSpat == null) { - return; - } - final Node selected = selectedSpat.getLookup().lookup(Node.class); - if (selected != null) { - setNeedsSave(true); - SceneApplication.getApplication().enqueue(new Callable() { - - public Object call() throws Exception { - doAddModel(file, selected, location); - return null; - } - }); - } else { - displayInfo("Please select a Node to attach to\nin the SceneExplorer."); - } - } - - public void doAddModel(Spatial file, Node selected, Vector3f location) { - ProgressHandle progressHandle = ProgressHandleFactory.createHandle("Adding Model.."); - progressHandle.start(); - try { - if (file != null) { - selected.attachChild(file); - if (location != null) { - Vector3f localVec = new Vector3f(); - selected.worldToLocal(location, localVec); - file.setLocalTranslation(localVec); - } - } - refreshSelected(); - addSpatialUndo(selected, file, null, jmeRootNode); - } catch (Exception ex) { - Confirmation msg = new NotifyDescriptor.Confirmation( - "Error importing " + file.getName() + "\n" + ex.toString(), - NotifyDescriptor.OK_CANCEL_OPTION, - NotifyDescriptor.ERROR_MESSAGE); - DialogDisplayer.getDefault().notifyLater(msg); - } - progressHandle.finish(); - - } +// public void addModel(final Spatial file) { +// addModel(file, null); +// } +// +// public void addModel(final Spatial file, final Vector3f location) { +// if (selectedSpat == null) { +// return; +// } +// final Node selected = selectedSpat.getLookup().lookup(Node.class); +// if (selected != null) { +// setNeedsSave(true); +// SceneApplication.getApplication().enqueue(new Callable() { +// +// public Object call() throws Exception { +// doAddModel(file, selected, location); +// return null; +// } +// }); +// } else { +// displayInfo("Please select a Node to attach to\nin the SceneExplorer."); +// } +// } +// +// public void doAddModel(Spatial file, Node selected, Vector3f location) { +// ProgressHandle progressHandle = ProgressHandleFactory.createHandle("Adding Model.."); +// progressHandle.start(); +// try { +// if (file != null) { +// selected.attachChild(file); +// if (location != null) { +// Vector3f localVec = new Vector3f(); +// selected.worldToLocal(location, localVec); +// file.setLocalTranslation(localVec); +// } +// } +// refreshSelected(); +// addSpatialUndo(selected, file, null, jmeRootNode); +// } catch (Exception ex) { +// Confirmation msg = new NotifyDescriptor.Confirmation( +// "Error importing " + file.getName() + "\n" + ex.toString(), +// NotifyDescriptor.OK_CANCEL_OPTION, +// NotifyDescriptor.ERROR_MESSAGE); +// DialogDisplayer.getDefault().notifyLater(msg); +// } +// progressHandle.finish(); +// +// } public void setNeedsSave(boolean state) { currentFileObject.setModified(state);