Fixes issue 17138: When you try to move the child tab, the focus goes directly to the header launching the autosave
authorMartin Taal <martin.taal@openbravo.com>
Thu, 12 May 2011 17:01:11 +0200
changeset 12135 ccdcc3aca320
parent 12134 3299a3e1ad8f
child 12136 fa4d6a6b3d7d
Fixes issue 17138: When you try to move the child tab, the focus goes directly to the header launching the autosave
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-eventhandler.js
--- a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-eventhandler.js	Thu May 12 16:44:43 2011 +0200
+++ b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-eventhandler.js	Thu May 12 17:01:11 2011 +0200
@@ -47,6 +47,14 @@
           canvas.pane.setAsActiveView();
           return true;
         }
+        
+        // when clicking in the tabbar
+        if (canvas.tabSet && canvas.tabSet.getSelectedTab() && canvas.tabSet.getSelectedTab().pane 
+            && canvas.tabSet.getSelectedTab().pane.setAsActiveView) {
+          canvas.tabSet.getSelectedTab().pane.setAsActiveView();
+          return true;
+        }
+        
         do {
           if (canvas.view && canvas.view.setAsActiveView) {
             canvas.view.setAsActiveView();