jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pmoua...@apache.org
Subject svn commit: r1204150 - /jmeter/trunk/src/reports/org/apache/jmeter/gui/util/ReportMenuBar.java
Date Sun, 20 Nov 2011 11:42:30 GMT
Author: pmouawad
Date: Sun Nov 20 11:42:30 2011
New Revision: 1204150

URL: http://svn.apache.org/viewvc?rev=1204150&view=rev
Log:
edit_remove is never initialized and not used.

Modified:
    jmeter/trunk/src/reports/org/apache/jmeter/gui/util/ReportMenuBar.java

Modified: jmeter/trunk/src/reports/org/apache/jmeter/gui/util/ReportMenuBar.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/reports/org/apache/jmeter/gui/util/ReportMenuBar.java?rev=1204150&r1=1204149&r2=1204150&view=diff
==============================================================================
--- jmeter/trunk/src/reports/org/apache/jmeter/gui/util/ReportMenuBar.java (original)
+++ jmeter/trunk/src/reports/org/apache/jmeter/gui/util/ReportMenuBar.java Sun Nov 20 11:42:30
2011
@@ -30,15 +30,15 @@ import javax.swing.JPopupMenu;
 import javax.swing.MenuElement;
 import javax.swing.UIManager;
 
-import org.apache.jmeter.report.gui.action.ReportActionRouter;
 import org.apache.jmeter.gui.action.ActionNames;
 import org.apache.jmeter.gui.action.KeyStrokes;
+import org.apache.jmeter.report.gui.action.ReportActionRouter;
 import org.apache.jmeter.util.JMeterUtils;
 import org.apache.jmeter.util.LocaleChangeEvent;
 import org.apache.jmeter.util.LocaleChangeListener;
 import org.apache.jmeter.util.SSLManager;
-import org.apache.jorphan.util.JOrphanUtils;
 import org.apache.jorphan.logging.LoggingManager;
+import org.apache.jorphan.util.JOrphanUtils;
 import org.apache.log.Logger;
 
 /**
@@ -66,9 +66,6 @@ public class ReportMenuBar extends JMenu
 
     private JMenu edit_add;
 
-    // JMenu edit_add_submenu;
-    private JMenuItem edit_remove; // TODO - should this be created?
-
     private JMenu runMenu;
 
     private JMenuItem run_start;
@@ -175,22 +172,10 @@ public class ReportMenuBar extends JMenu
         // If we are enabling the Edit-->Add menu item, then we also need to
         // enable the Edit menu. The Edit menu may already be enabled, but
         // there's no harm it trying to enable it again.
-        if (enabled) {
-            setEditEnabled(true);
-        } else {
-            // If we are disabling the Edit-->Add menu item and the
-            // Edit-->Remove menu item is disabled, then we also need to
-            // disable the Edit menu.
-            // The Java Look and Feel Guidelines say to disable a menu if all
-            // menu items are disabled.
-            if (!edit_remove.isEnabled()) {
-                editMenu.setEnabled(false);
-            }
-        }
+        setEditEnabled(enabled);
     }
 
     public void setEditRemoveEnabled(boolean enabled) {
-        edit_remove.setEnabled(enabled);
         // If we are enabling the Edit-->Remove menu item, then we also need to
         // enable the Edit menu. The Edit menu may already be enabled, but
         // there's no harm it trying to enable it again.



Mime
View raw message