Bug 142140

Summary: Document::recalcStyle() shouldn't call viewportContentsChanged() if there is a pending layout
Product: WebKit Reporter: Simon Fraser (smfr) <simon.fraser>
Component: Layout and RenderingAssignee: Chris Dumez <cdumez>
Status: RESOLVED FIXED    
Severity: Normal CC: cdumez, commit-queue, esprehn+autocc, kangil.han, simon.fraser
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch none

Description Simon Fraser (smfr) 2015-02-28 16:33:59 PST
It's wasteful for viewportContentsChanged() to be called from recalcStyle() if a layout is pending, because that's going to move things around, and then we'll call viewportContentsChanged() again.
Comment 1 Simon Fraser (smfr) 2015-02-28 16:34:58 PST
It's actually positively bad, because resumePausedImageAnimationsIfNeeded() does repaints which assume the render tree is in a valid state.
Comment 2 Chris Dumez 2015-03-04 11:50:55 PST
I am busy with other things right now but I'll try to get to it asap. If someone else want to volunteer to make the change before then, feel free to reassign though.
Comment 3 Chris Dumez 2015-03-04 13:18:42 PST
Created attachment 247887 [details]
Patch
Comment 4 WebKit Commit Bot 2015-03-05 20:38:42 PST
Comment on attachment 247887 [details]
Patch

Clearing flags on attachment: 247887

Committed r181133: <http://trac.webkit.org/changeset/181133>
Comment 5 WebKit Commit Bot 2015-03-05 20:38:48 PST
All reviewed patches have been landed.  Closing bug.