details:   https://code.openbravo.com/erp/devel/pi/rev/a07f840d54af
changeset: 22764:a07f840d54af
user:      Asier Lostalé <asier.lostale <at> openbravo.com>
date:      Tue Mar 25 10:24:01 2014 +0100
summary:   fixed bug 26078, related to bug 25910: fixed CI

  CI was failing due to the timeout introduced in quick run widget in order to
  prevent quick launch to be kept open just after selecting an item.

  This caused sync test to fail as it was closing and opening profile widget 
without
  waiting the 50ms defined in the timeout.

  Current patch adds this timeout just to quick launch and not to all quick run 
widgets

diffstat:

 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quick-launch.js
    |  18 ++++++++-
 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quickrun-widget.js
 |   9 +----
 2 files changed, 17 insertions(+), 10 deletions(-)

diffs (69 lines):

diff -r 7662abb410cf -r a07f840d54af 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quick-launch.js
--- 
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quick-launch.js
        Mon Mar 24 16:40:26 2014 +0100
+++ 
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quick-launch.js
        Tue Mar 25 10:24:01 2014 +0100
@@ -11,7 +11,7 @@
  * under the License.
  * The Original Code is Openbravo ERP.
  * The Initial Developer of the Original Code is Openbravo SLU
- * All portions are Copyright (C) 2011-2013 Openbravo SLU
+ * All portions are Copyright (C) 2011-2014 Openbravo SLU
  * All Rights Reserved.
  * Contributor(s):  ______________________________________.
  ************************************************************************
@@ -111,6 +111,20 @@
     valueField.setElementValue('', null);
   },
 
+  click: function () {
+    if (!this.showing) {
+      if (!this.executingAction) {
+        this.setExecutingAction();
+      } else {
+        // do nothing: action has just been launched, preventing it to be 
triggered
+        // twice at the same time
+        // see issue #25910
+        return false;
+      }
+    }
+    this.Super('click', arguments)
+  },
+
   // handle the case that someone entered a url in the quick launch
   doHide: function () {
     if (this.members[2].getField('value').getValue() && 
this.members[2].getField('value').getValue().contains('?')) {
@@ -122,7 +136,7 @@
     if (this.members[1].getMembers()) {
       
this.members[1].destroyAndRemoveMembers(this.members[1].getMembers().duplicate());
     }
-
+    this.setExecutingAction();
     this.Super('doHide', arguments);
   },
 
diff -r 7662abb410cf -r a07f840d54af 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quickrun-widget.js
--- 
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quickrun-widget.js
     Mon Mar 24 16:40:26 2014 +0100
+++ 
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/navbar/ob-quickrun-widget.js
     Tue Mar 25 10:24:01 2014 +0100
@@ -153,14 +153,8 @@
     if (this.showing) {
       this.doHide();
       return false;
-    } else if (!this.executingAction) {
-      this.setExecutingAction();
+    } else {
       this.doShow();
-    } else {
-      // do nothing: action has just been launched, preventing it to be 
triggered
-      // twice at the same time
-      // see issue #25910
-      return false;
     }
   },
 
@@ -277,7 +271,6 @@
     }
 
     this.focus(); // keeping focus in SC component
-    this.setExecutingAction();
     if (isc.isA.Canvas(this.focusOnHide)) {
       // setting the focus back to a SC component so keyboard shortcuts 
continue
       // working (they do not if focus is in browser). This is needed to be 
done

------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/13534_NeoTech
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to