From 2cf1455867bbb0f9d7ec0ab0aa9598c6649cc94e Mon Sep 17 00:00:00 2001 From: "bre..ns" Date: Fri, 24 Aug 2012 04:13:02 +0000 Subject: [PATCH] removed the leftovers of the terrain editor border tool git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9682 75d07b2b-3a1a-0410-a2c5-0572b91ccdca --- .../jme3/gde/terraineditor/Bundle.properties | 5 -- .../TerrainEditorController.java | 1 - .../TerrainEditorTopComponent.form | 87 ------------------- .../TerrainEditorTopComponent.java | 80 ----------------- 4 files changed, 173 deletions(-) diff --git a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/Bundle.properties b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/Bundle.properties index 0568242d3..e325845c1 100644 --- a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/Bundle.properties +++ b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/Bundle.properties @@ -125,15 +125,10 @@ TerrainEditorTopComponent.levelAbsoluteHeightField.text=0 TerrainEditorTopComponent.slopeTerrainButton.toolTipText=Slope terrain TerrainEditorTopComponent.slopeTerrainButton.text= TerrainEditorTopComponent.slopeLockCheckbox.text=Contain -TerrainEditorTopComponent.jLabel7.text= -TerrainEditorTopComponent.borderDistanceField.text=0 -TerrainEditorTopComponent.borderHeightField.text=0 TerrainEditorTopComponent.PrecisionCheckbox.text=Snap TerrainEditorTopComponent.PrecisionCheckbox.tooltip=Snap directly to the defined height, instead of smoothly adjusting TerrainEditorTopComponent.AbsoluteCheckbox.text=Absolute TerrainEditorTopComponent.AbsoluteCheckbox.tooltip=Define the height to adjust to, instead of using the marker TerrainEditorTopComponent.slopeLockCheckbox.tooltip=Contains the slope between the two slope nodes -TerrainEditorTopComponent.borderDistanceLabel.text=Distance -TerrainEditorTopComponent.borderHeightLAbel.text=Height TerrainEditorTopComponent.borderDistanceLabel.tooltip=Distance means how far from the terrain's edge the border will be raised (thickness of the border). TerrainEditorTopComponent.borderHeightLAbel.tooltip=Height means how high the border will go (also accept negative values). diff --git a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorController.java b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorController.java index d4007696b..4ff8dbefd 100644 --- a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorController.java +++ b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorController.java @@ -53,7 +53,6 @@ import com.jme3.terrain.Terrain; import com.jme3.texture.Texture; import com.jme3.texture.Texture.WrapMode; import com.jme3.util.SkyFactory; -import com.sun.imageio.plugins.common.ImageUtil; import java.awt.image.BufferedImage; import java.beans.PropertyChangeEvent; import java.io.File; diff --git a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.form b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.form index 035b38247..60b096578 100644 --- a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.form +++ b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.form @@ -212,93 +212,6 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.java b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.java index c70592f16..a20935465 100644 --- a/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.java +++ b/sdk/jme3-terrain-editor/src/com/jme3/gde/terraineditor/TerrainEditorTopComponent.java @@ -240,13 +240,6 @@ public final class TerrainEditorTopComponent extends TopComponent implements Sce slopeBrushPanel = new javax.swing.JPanel(); slopePrecisionCheckbox = new javax.swing.JCheckBox(); slopeLockCheckbox = new javax.swing.JCheckBox(); - borderBrushPanel = new javax.swing.JPanel(); - borderPrecisionCheckbox = new javax.swing.JCheckBox(); - jLabel7 = new javax.swing.JLabel(); - borderDistanceLabel = new javax.swing.JLabel(); - borderDistanceField = new javax.swing.JFormattedTextField(NumberFormat.getInstance()); - borderHeightLAbel = new javax.swing.JLabel(); - borderHeightField = new javax.swing.JFormattedTextField(NumberFormat.getInstance()); jToolBar1 = new javax.swing.JToolBar(); createTerrainButton = new javax.swing.JButton(); jSeparator1 = new javax.swing.JToolBar.Separator(); @@ -399,48 +392,6 @@ public final class TerrainEditorTopComponent extends TopComponent implements Sce }); slopeBrushPanel.add(slopeLockCheckbox); - borderBrushPanel.setBackground(new java.awt.Color(204, 204, 204)); - borderBrushPanel.setOpaque(false); - borderBrushPanel.setLayout(new java.awt.GridLayout(3, 2)); - - org.openide.awt.Mnemonics.setLocalizedText(borderPrecisionCheckbox, org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.PrecisionCheckbox.text")); // NOI18N - borderPrecisionCheckbox.setToolTipText(org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.PrecisionCheckbox.tooltip")); // NOI18N - borderPrecisionCheckbox.addActionListener(new java.awt.event.ActionListener() { - public void actionPerformed(java.awt.event.ActionEvent evt) { - borderPrecisionCheckboxActionPerformed(evt); - } - }); - borderBrushPanel.add(borderPrecisionCheckbox); - - org.openide.awt.Mnemonics.setLocalizedText(jLabel7, org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.jLabel7.text")); // NOI18N - borderBrushPanel.add(jLabel7); - - org.openide.awt.Mnemonics.setLocalizedText(borderDistanceLabel, org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderDistanceLabel.text")); // NOI18N - borderDistanceLabel.setToolTipText(org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderDistanceLabel.tooltip")); // NOI18N - borderBrushPanel.add(borderDistanceLabel); - - borderDistanceField.setText(org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderDistanceField.text")); // NOI18N - borderDistanceField.setToolTipText(org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderDistanceLabel.tooltip")); // NOI18N - borderDistanceField.addKeyListener(new java.awt.event.KeyAdapter() { - public void keyTyped(java.awt.event.KeyEvent evt) { - borderDistanceFieldKeyTyped(evt); - } - }); - borderBrushPanel.add(borderDistanceField); - - org.openide.awt.Mnemonics.setLocalizedText(borderHeightLAbel, org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderHeightLAbel.text")); // NOI18N - borderHeightLAbel.setToolTipText(org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderHeightLAbel.tooltip")); // NOI18N - borderBrushPanel.add(borderHeightLAbel); - - borderHeightField.setText(org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderHeightField.text")); // NOI18N - borderHeightField.setToolTipText(org.openide.util.NbBundle.getMessage(TerrainEditorTopComponent.class, "TerrainEditorTopComponent.borderHeightLAbel.tooltip")); // NOI18N - borderHeightField.addKeyListener(new java.awt.event.KeyAdapter() { - public void keyTyped(java.awt.event.KeyEvent evt) { - borderHeightFieldKeyTyped(evt); - } - }); - borderBrushPanel.add(borderHeightField); - setBackground(java.awt.Color.gray); jToolBar1.setBackground(new java.awt.Color(204, 204, 204)); @@ -998,26 +949,8 @@ public final class TerrainEditorTopComponent extends TopComponent implements Sce levelAbsoluteHeightField.setEnabled(levelAbsoluteCheckbox.isEnabled()); }//GEN-LAST:event_levelAbsoluteCheckboxActionPerformed - private void borderPrecisionCheckboxActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_borderPrecisionCheckboxActionPerformed - updateBorderToolParams(); - }//GEN-LAST:event_borderPrecisionCheckboxActionPerformed - - private void borderDistanceFieldKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_borderDistanceFieldKeyTyped - updateBorderToolParams(); - }//GEN-LAST:event_borderDistanceFieldKeyTyped - - private void borderHeightFieldKeyTyped(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_borderHeightFieldKeyTyped - updateBorderToolParams(); - }//GEN-LAST:event_borderHeightFieldKeyTyped - // Variables declaration - do not modify//GEN-BEGIN:variables private javax.swing.JButton addTextureButton; - private javax.swing.JPanel borderBrushPanel; - private javax.swing.JFormattedTextField borderDistanceField; - private javax.swing.JLabel borderDistanceLabel; - private javax.swing.JFormattedTextField borderHeightField; - private javax.swing.JLabel borderHeightLAbel; - private javax.swing.JCheckBox borderPrecisionCheckbox; private javax.swing.JButton createTerrainButton; private javax.swing.JToggleButton eraseButton; private javax.swing.JPanel fractalBrushPanel; @@ -1029,7 +962,6 @@ public final class TerrainEditorTopComponent extends TopComponent implements Sce private javax.swing.JLabel jLabel3; private javax.swing.JLabel jLabel4; private javax.swing.JLabel jLabel6; - private javax.swing.JLabel jLabel7; private javax.swing.JPanel jPanel2; private javax.swing.JScrollPane jScrollPane1; private javax.swing.JScrollPane jScrollPane2; @@ -1125,16 +1057,6 @@ public final class TerrainEditorTopComponent extends TopComponent implements Sce } catch (NumberFormatException e) {} } - private void updateBorderToolParams() { - try { - BorderExtraToolParams params = new BorderExtraToolParams(); - params.precision = borderPrecisionCheckbox.isSelected(); - params.height = new Float(borderHeightField.getText()); - params.distance = new Float(borderDistanceField.getText()); - toolController.setExtraToolParams(params); - } catch (NumberFormatException e) {} - } - private void updateRoughenFractalToolParams() { try { RoughExtraToolParams params = new RoughExtraToolParams(); @@ -1157,8 +1079,6 @@ public final class TerrainEditorTopComponent extends TopComponent implements Sce updateLevelToolParams(); else if (toolController.getCurrentTerrainTool().getClass() == SlopeTerrainTool.class) updateSlopeToolParams(); - else if (toolController.getCurrentTerrainTool().getClass() == BorderTerrainTool.class) - updateBorderToolParams(); } }