[richfaces-svn-commits] JBoss Rich Faces SVN: r9129 - trunk/ui/dataFilterSlider/src/main/resources/org/richfaces/renderkit/html/scripts.

richfaces-svn-commits at lists.jboss.org richfaces-svn-commits at lists.jboss.org
Fri Jun 20 07:22:48 EDT 2008


Author: abelevich
Date: 2008-06-20 07:22:48 -0400 (Fri, 20 Jun 2008)
New Revision: 9129

Modified:
   trunk/ui/dataFilterSlider/src/main/resources/org/richfaces/renderkit/html/scripts/datafilterslider.js
Log:
http://jira.jboss.com/jira/browse/RF-2830

Modified: trunk/ui/dataFilterSlider/src/main/resources/org/richfaces/renderkit/html/scripts/datafilterslider.js
===================================================================
--- trunk/ui/dataFilterSlider/src/main/resources/org/richfaces/renderkit/html/scripts/datafilterslider.js	2008-06-20 09:39:07 UTC (rev 9128)
+++ trunk/ui/dataFilterSlider/src/main/resources/org/richfaces/renderkit/html/scripts/datafilterslider.js	2008-06-20 11:22:48 UTC (rev 9129)
@@ -71,14 +71,17 @@
     this.eventMouseDown = this.startDrag.bindAsEventListener(this);
     this.eventMouseUp   = this.endDrag.bindAsEventListener(this);
     this.eventMouseMove = this.update.bindAsEventListener(this);
+    this.loadEventHandler = this.initHandles.bindAsEventListener(this);
 
     Event.observe(this.track, "mousedown", this.eventMouseDown);
     Event.observe(document, "mouseup", this.eventMouseUp);
     Event.observe(document, "mousemove", this.eventMouseMove);
-    // Initialize handles in reverse (make sure first handle is active)
+ // Initialize handles in reverse (make sure first handle is active)
     this.handles[0].style.visibility="hidden";
-	setTimeout(this.initHandles.bind(this), 100);
-    this.initialized = true;
+
+//  http://jira.jboss.com/jira/browse/RF-2830
+    Event.observe(window, "load", this.loadEventHandler);
+	this.initialized = true;
     
   },
   initHandles: function() {
@@ -105,6 +108,8 @@
     Event.stopObserving(this.track, "mousedown", this.eventMouseDown);
     Event.stopObserving(document, "mouseup", this.eventMouseUp);
     Event.stopObserving(document, "mousemove", this.eventMouseMove);
+    Event.stopObserving(window, "load", this.loadEventHandler);
+    
     this.handles.each( function(h) {
       Event.stopObserving(h, "mousedown", slider.eventMouseDown);
     });




More information about the richfaces-svn-commits mailing list