myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lof...@apache.org
Subject svn commit: r950392 - /myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-sheet.js
Date Wed, 02 Jun 2010 07:02:11 GMT
Author: lofwyr
Date: Wed Jun  2 07:02:10 2010
New Revision: 950392

URL: http://svn.apache.org/viewvc?rev=950392&view=rev
Log:
TOBAGO-887: SimpleSheet headers are broken in Firefox 3.0

Modified:
    myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-sheet.js

Modified: myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-sheet.js
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-sheet.js?rev=950392&r1=950391&r2=950392&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-sheet.js
(original)
+++ myfaces/tobago/branches/tobago-1.0.x/theme/standard/src/main/resources/org/apache/myfaces/tobago/renderkit/html/standard/standard/script/tobago-sheet.js
Wed Jun  2 07:02:10 2010
@@ -380,7 +380,7 @@ Tobago.Sheet.prototype.setup = function(
         this.setupHeader();
         this.adjustScrollBars();
       }
-
+      this.adjustHeaderDivFirefoxFix();
 
       if (this.firstRowId) {
         this.tobagoLastClickedRowId = this.firstRowId;
@@ -761,8 +761,14 @@ Tobago.Sheet.prototype.adjustHeaderDiv =
     //  LOG.debug("filler      :" + fillBox.clientWidth);
     //  LOG.debug("fillerstyle :" + fillBox.style.width);
     //  LOG.debug("##########################################");
+};
 
-  // XXX fix for Firefox 3.0
+Tobago.Sheet.prototype.adjustHeaderDivFirefoxFix = function () {
+  // XXX fix for Firefox 3.0 (3.5 and 3.6 are working)
+  var headerDiv = Tobago.element(this.headerDivId);
+  if (!headerDiv) {
+    return;
+  }
   if (navigator.userAgent.indexOf("Firefox/3.0") > -1) {
     var length = headerDiv.childNodes.length;
     for (var i = 0; i < length; i++) {
@@ -773,7 +779,7 @@ Tobago.Sheet.prototype.adjustHeaderDiv =
       }
     }
   }
-  };
+};
 
 Tobago.Sheet.prototype.beginResize = function(event) {
     if (! event) {
@@ -832,6 +838,7 @@ Tobago.Sheet.prototype.endResize = funct
       this.adjustHeaderDiv();
       this.adjustResizer();
       this.storeSizes();
+      this.adjustHeaderDivFirefoxFix();
       delete this.resizerId;
     }
   };



Mime
View raw message