Author: vmolotkov
Date: 2007-11-05 07:59:39 -0500 (Mon, 05 Nov 2007)
New Revision: 3757
Modified:
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/LayoutManager.js
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js
trunk/sandbox/ui/orderingList/src/main/templates/org/richfaces/htmlOrderingList.jspx
Log:
fixed bug for IE
Modified:
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/LayoutManager.js
===================================================================
---
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/LayoutManager.js 2007-11-05
12:44:15 UTC (rev 3756)
+++
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/LayoutManager.js 2007-11-05
12:59:39 UTC (rev 3757)
@@ -29,7 +29,7 @@
if (i == contentCells.length - 1) {
width = width + LayoutManager.SCROLL_WIDTH;
headerCells[i].firstChild.style.width = width;
- headerCells[i].style.width = width;
+ headerCells[i].style.width = width;
} else {
headerCells[i].firstChild.style.width = width;
headerCells[i].style.width = width;
@@ -40,4 +40,8 @@
LayoutManager.prototype.scrollHandler = function(obj) {
obj.headerDiv.scrollLeft = obj.contentDiv.scrollLeft;
+}
+
+LayoutManager.isIE = function() {
+ return (/MSIE/.test(navigator.userAgent) && !window.opera);
}
\ No newline at end of file
Modified:
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js
===================================================================
---
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js 2007-11-05
12:44:15 UTC (rev 3756)
+++
trunk/sandbox/ui/orderingList/src/main/resources/org/richfaces/renderkit/html/scripts/OrderingList.js 2007-11-05
12:59:39 UTC (rev 3757)
@@ -29,6 +29,10 @@
this.focusKeeper.onkeydown = function(e) {
obj.onkeydownHandler(window.event || e);
}
+
+ //FIXME
+ var layoutManager = new LayoutManager('internal_header_tab',
'internal_tab');
+ layoutManager.widthSynchronization();
}
Shuttle.ASC = "acs";
Modified:
trunk/sandbox/ui/orderingList/src/main/templates/org/richfaces/htmlOrderingList.jspx
===================================================================
---
trunk/sandbox/ui/orderingList/src/main/templates/org/richfaces/htmlOrderingList.jspx 2007-11-05
12:44:15 UTC (rev 3756)
+++
trunk/sandbox/ui/orderingList/src/main/templates/org/richfaces/htmlOrderingList.jspx 2007-11-05
12:59:39 UTC (rev 3757)
@@ -19,14 +19,12 @@
<script type="text/javascript">
function init() {
var shuttle = new Shuttle('#{clientId}', 'internal_tab',
'#{clientId}focusKeeper', '#{clientId}valueKeeper');
- var layoutManager = new LayoutManager('internal_header_tab',
'internal_tab');
- layoutManager.widthSynchronization();
Shuttle.setFocus('#{clientId}focusKeeper');
document.getElementById('up').onclick = function()
{shuttle.moveSelectedItems('up');};
document.getElementById('down').onclick = function()
{shuttle.moveSelectedItems('down');};
document.getElementById('first').onclick = function()
{shuttle.moveSelectedItems('first');};
document.getElementById('last').onclick = function()
{shuttle.moveSelectedItems('last');};
- document.getElementById('#{clientId}table').onclick = function(e)
{shuttle.onclickHandler(window.event || e);}
+ document.getElementById('#{clientId}table').onclick = function(e)
{shuttle.onclickHandler(window.event || e);};
}
</script>
@@ -64,8 +62,9 @@
<a id="last" href="#" >last</a>
</div>
<script type="text/javascript">
- document.body.onselectstart = function() {return false;};
+ //document.body.onselectstart = function() {return false;};
document.body.className = "body";
- document.body.onload = init();
+ if(LayoutManager.isIE()) document.body.onload = init;
+ else document.body.onload = init();
</script>
</f:root>
\ No newline at end of file
Show replies by date