jmeter-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From pmoua...@apache.org
Subject svn commit: r1765437 - in /jmeter/trunk: src/core/org/apache/jmeter/gui/SavePropertyDialog.java xdocs/changes.xml
Date Tue, 18 Oct 2016 13:30:22 GMT
Author: pmouawad
Date: Tue Oct 18 13:30:22 2016
New Revision: 1765437

URL: http://svn.apache.org/viewvc?rev=1765437&view=rev
Log:
Bug 60267 - UX : In View Results Tree it should be possible to close the Configure popup by
typing escape
Contributed by Ubik Load Pack (support at ubikloadpack.com)
Bugzilla Id: 60267

Modified:
    jmeter/trunk/src/core/org/apache/jmeter/gui/SavePropertyDialog.java
    jmeter/trunk/xdocs/changes.xml

Modified: jmeter/trunk/src/core/org/apache/jmeter/gui/SavePropertyDialog.java
URL: http://svn.apache.org/viewvc/jmeter/trunk/src/core/org/apache/jmeter/gui/SavePropertyDialog.java?rev=1765437&r1=1765436&r2=1765437&view=diff
==============================================================================
--- jmeter/trunk/src/core/org/apache/jmeter/gui/SavePropertyDialog.java (original)
+++ jmeter/trunk/src/core/org/apache/jmeter/gui/SavePropertyDialog.java Tue Oct 18 13:30:22
2016
@@ -31,11 +31,17 @@ import java.lang.reflect.Method;
 import java.util.HashMap;
 import java.util.Map;
 
+import javax.swing.AbstractAction;
+import javax.swing.Action;
+import javax.swing.InputMap;
 import javax.swing.JButton;
 import javax.swing.JCheckBox;
+import javax.swing.JComponent;
 import javax.swing.JDialog;
 import javax.swing.JPanel;
+import javax.swing.JRootPane;
 
+import org.apache.jmeter.gui.action.KeyStrokes;
 import org.apache.jmeter.samplers.SampleSaveConfiguration;
 import org.apache.jmeter.util.JMeterUtils;
 import org.apache.jorphan.logging.LoggingManager;
@@ -114,6 +120,26 @@ public class SavePropertyDialog extends
             }
         });
     }
+    
+    @Override
+    protected JRootPane createRootPane() {
+        JRootPane rootPane = new JRootPane();
+        Action escapeAction = new AbstractAction("ESCAPE") {
+            /**
+             * 
+             */
+            private static final long serialVersionUID = 2208129319916921772L;
+
+            @Override
+            public void actionPerformed(ActionEvent e) {
+                setVisible(false);
+            }
+        };
+        InputMap inputMap = rootPane.getInputMap(JComponent.WHEN_IN_FOCUSED_WINDOW);
+        inputMap.put(KeyStrokes.ESC, escapeAction.getValue(Action.NAME));
+        rootPane.getActionMap().put(escapeAction.getValue(Action.NAME), escapeAction);
+        return rootPane;
+    }
 
     @Override
     public void actionPerformed(ActionEvent e) {

Modified: jmeter/trunk/xdocs/changes.xml
URL: http://svn.apache.org/viewvc/jmeter/trunk/xdocs/changes.xml?rev=1765437&r1=1765436&r2=1765437&view=diff
==============================================================================
--- jmeter/trunk/xdocs/changes.xml [utf-8] (original)
+++ jmeter/trunk/xdocs/changes.xml [utf-8] Tue Oct 18 13:30:22 2016
@@ -127,6 +127,7 @@ Summary
     <li><bug>60109</bug>Summariser : Make it ignore TC generated SampleResult
in its summary computations</li>
     <li><bug>59948</bug>Add a formatted and sane HTML source code render
to View Results Tree</li>
     <li><bug>60252</bug>Add sent kbytes/s to Aggregate Report and Summary
report</li>
+    <li><bug>60267</bug>UX : In View Results Tree it should be possible
to close the Configure popup by typing escape. Contributed by Ubik Load Pack (support at ubikloadpack.com)</li>
 </ul>
 
 <h3>Timers, Assertions, Config, Pre- &amp; Post-Processors</h3>



Mime
View raw message