details:   /erp/devel/pi/rev/99f610e7da8b
changeset: 10844:99f610e7da8b
user:      Martin Taal <martin.taal <at> openbravo.com>
date:      Wed Feb 23 14:30:35 2011 +0100
summary:   Solve cosmetic issue in chrome when editing row

diffstat:

 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
                                                             |   5 +--
 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-grid.js
                                                             |  16 ++++++++-
 
modules/org.openbravo.client.application/web/org.openbravo.userinterface.smartclient/openbravo/skins/3.00/org.openbravo.client.application/ob-grid-styles.js
 |   1 +
 3 files changed, 15 insertions(+), 7 deletions(-)

diffs (59 lines):

diff -r c6bed2436bbf -r 99f610e7da8b 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
--- 
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
  Wed Feb 23 13:44:26 2011 +0100
+++ 
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-form.js
  Wed Feb 23 14:30:35 2011 +0100
@@ -449,10 +449,7 @@
     var previousAllItemsDisabled = this.allItemsDisabled;
     this.allItemsDisabled = state;
     if (previousAllItemsDisabled !== this.allItemsDisabled) {
-      var editRow = this.view.viewGrid.getEditRow();
-      if (editRow || editRow === 0) {
-        this.view.viewGrid.refreshRow(editRow);
-      }
+      this.view.viewGrid.refreshEditRow();
     }
   },
   
diff -r c6bed2436bbf -r 99f610e7da8b 
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-grid.js
--- 
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-grid.js
  Wed Feb 23 13:44:26 2011 +0100
+++ 
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/ob-view-grid.js
  Wed Feb 23 14:30:35 2011 +0100
@@ -1316,9 +1316,6 @@
       this.getEditForm().setFocusItem(this.getField(colNum).name);
     }
     
-    // will be set back on ficreturn
-    this.getEditForm().setDisabled(true);
-    
     var record = this.getRecord(rowNum);
     
     this.view.isEditingGrid = true;
@@ -1384,6 +1381,19 @@
     return ret;
   },
   
+  refreshEditRow: function() {
+    var editRow = this.view.viewGrid.getEditRow();
+    if (editRow || editRow === 0) {
+      // don't refresh the frozen fields, this give strange
+      // styling issues in chrome
+      for (var i = 0; i < this.view.viewGrid.fields.length; i++) {
+        if (!this.fieldIsFrozen(i)) {
+          this.view.viewGrid.refreshCell(editRow, i, true);
+        }
+      }
+    }
+  },
+  
   // the form gets recreated many times, maintain the already read valuemap
   getEditorValueMap: function(field, values){
     var editRow = this.getEditRow(), editValues = this.getEditValues(editRow);
diff -r c6bed2436bbf -r 99f610e7da8b 
modules/org.openbravo.client.application/web/org.openbravo.userinterface.smartclient/openbravo/skins/3.00/org.openbravo.client.application/ob-grid-styles.js
--- 
a/modules/org.openbravo.client.application/web/org.openbravo.userinterface.smartclient/openbravo/skins/3.00/org.openbravo.client.application/ob-grid-styles.js
      Wed Feb 23 13:44:26 2011 +0100
+++ 
b/modules/org.openbravo.client.application/web/org.openbravo.userinterface.smartclient/openbravo/skins/3.00/org.openbravo.client.application/ob-grid-styles.js
      Wed Feb 23 14:30:35 2011 +0100
@@ -37,6 +37,7 @@
   headerMenuButtonSrc: 
'[SKIN]/../../org.openbravo.client.application/images/grid/gridHeaderMenuButton.png',
   hoverWidth: 200,
   editLinkColumnWidth: 58,
+  recordComponentHeight: 19,
 
   summaryRowConstructor: 'OBGridSummary',
   summaryRowDefaults:{

------------------------------------------------------------------------------
Free Software Download: Index, Search & Analyze Logs and other IT data in 
Real-Time with Splunk. Collect, index and harness all the fast moving IT data 
generated by your applications, servers and devices whether physical, virtual
or in the cloud. Deliver compliance at lower cost and gain new business 
insights. http://p.sf.net/sfu/splunk-dev2dev 
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits

Reply via email to