(In reply to Olli Pettay [:smaug] from comment #28) > do you know what exactly under ProcessPendingUpdates() call makes this to work? (ProcessPendingUpdates() does so many different things) A call of [nsViewManager::CallWillPaintOnObservers() in ProcessPendingUpdates()](https://searchfox.org/mozilla-central/rev/c21d6620d384dfb13ede6054015da05a6353b899/view/nsViewManager.cpp#1017,1028) flushes the positioned element as expected. It just calls [nsIPresShell::WillPaint()](), then, [it makes paint observers in root precContext](https://searchfox.org/mozilla-central/rev/c21d6620d384dfb13ede6054015da05a6353b899/layout/base/nsPresContext.cpp#2963-2970) and calls {FlushPendingNotifications(ChangesToFlush(FlushType::InterruptibleLayout, false));`. I'm still not sure which observer flushes it.
Bug 1506508 Comment 29 Edit History
Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.
(In reply to Olli Pettay [:smaug] from comment #28) > do you know what exactly under ProcessPendingUpdates() call makes this to work? (ProcessPendingUpdates() does so many different things) A call of [nsViewManager::CallWillPaintOnObservers() in ProcessPendingUpdates()](https://searchfox.org/mozilla-central/rev/c21d6620d384dfb13ede6054015da05a6353b899/view/nsViewManager.cpp#1017,1028) flushes the positioned element as expected. It just calls [nsIPresShell::WillPaint()](), then, [it makes paint observers in root precContext](https://searchfox.org/mozilla-central/rev/c21d6620d384dfb13ede6054015da05a6353b899/layout/base/nsPresContext.cpp#2963-2970) and calls `FlushPendingNotifications(ChangesToFlush(FlushType::InterruptibleLayout, false));`. I'm still not sure which observer flushes it.