Details - Web 2.0 & AJAX :: is there a onreflowcompleted handler?

This thread was displayed: 183 times


Starting with 17th May 2007, Adobe Systems will stop offering support for any version of the discontinued InterAKT products. As a result, we will not answer to new support incidents starting with May 17th, 2007. Pending support incidents will still be followed in order to be closed. The product forums will remain open and be transformed in user-to-user forums. The general forums will be made read-only and not allow new posts or comments.

For more information about the affected products visit: www.interaktonline.com/Support/

View Threaded Show descending
Clemens Cap
05-12-2006 23:02:31 GMT +2

I have a longer text portion which I get from the server using an ajax request. I then write this text via innerHTML  into a scrollable div. Finally the scrollable div is scrolled to the bottom.


My problem: If I scroll to the bottom immediately after writing to innerHTML, this seems to be too early, since the Firefox still is busy relayouting the written innerHTML. I solve this presently by providing a small timeout and doing the scroll via setTimeout. However I wather have a event handler which tells me when the relayouting has been finished.


1) Is there such a handler in Javascript?

2) Is there such a handler in Firefox XPCom?

3) Any other ideas to have a more elegant solution than the present one ?


Back | Reply | Quote | Top
Andrei DRAGOMIR[InterAKT]Adobe Systems Romania staff
06-13-2006 13:37:33 GMT +2

Hello Clemens. 

To my knowledge, there is no event handler for document reflow in javascript. Also, the problem with XPCom is that you would probably have issues with unpriviledged scripts. Besides, firefox implements either a network-chunk reflow mechanism (the default) which can be overridden with a timeout mechanism. I do not know of any event handler being triggered on page reflow. 

I believe that your issue could be some because of some rowser quirks. If you could give me a link to the page, I could look at it to see if there is some other workaround. 

Regards, 

Andrei

Reply | Quote | Top
Home > Support > Forums > Web 2.0 & AJAX > Details - Web 2.0 & AJAX
Adobe acquired InterAKT
InterAKT has been acquired by Adobe.
Learn more
 
© Adobe Systems Romania. All rights reserved.