Author: sebb
Date: Thu Oct  4 03:39:10 2007
New Revision: 581839

URL: http://svn.apache.org/viewvc?rev=581839&view=rev
Log:
Allow Action to continue even if there is a Gui update problem

Modified:
    jakarta/jmeter/trunk/src/core/org/apache/jmeter/gui/action/ActionRouter.java

Modified: 
jakarta/jmeter/trunk/src/core/org/apache/jmeter/gui/action/ActionRouter.java
URL: 
http://svn.apache.org/viewvc/jakarta/jmeter/trunk/src/core/org/apache/jmeter/gui/action/ActionRouter.java?rev=581839&r1=581838&r2=581839&view=diff
==============================================================================
--- 
jakarta/jmeter/trunk/src/core/org/apache/jmeter/gui/action/ActionRouter.java 
(original)
+++ 
jakarta/jmeter/trunk/src/core/org/apache/jmeter/gui/action/ActionRouter.java 
Thu Oct  4 03:39:10 2007
@@ -66,9 +66,15 @@
        }
 
        private void performAction(final ActionEvent e) {
+               String actionCommand = e.getActionCommand();
                try {
-                       GuiPackage.getInstance().updateCurrentGui();
-                       Set commandObjects = (Set) 
commands.get(e.getActionCommand());
+                       try {
+                           GuiPackage.getInstance().updateCurrentGui();
+                       } catch (Exception err){
+                               log.error("performAction(" + actionCommand + ") 
updateCurrentGui() on" + e.toString() + " caused", err);                        
        
+                               JMeterUtils.reportErrorToUser("Problem updating 
GUI - see log file for details");
+                       }
+                       Set commandObjects = (Set) commands.get(actionCommand);
                        Iterator iter = commandObjects.iterator();
                        while (iter.hasNext()) {
                                try {
@@ -83,8 +89,8 @@
                                }
                        }
                } catch (NullPointerException er) {
-                       log.error("performAction(" + e.getActionCommand() + ") 
" + e.toString() + " caused", er);
-                       JMeterUtils.reportErrorToUser("Sorry, this feature (" + 
e.getActionCommand() + ") not yet implemented");
+                       log.error("performAction(" + actionCommand + ") " + 
e.toString() + " caused", er);
+                       JMeterUtils.reportErrorToUser("Sorry, this feature (" + 
actionCommand + ") not yet implemented");
                }
        }
 



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to