Bug 77429

Summary: [Chromium] ChromeClientImpl::dispatchViewportPropertiesDidChange is repeatedly called in Google News
Product: WebKit Reporter: Fady Samuel <fsamuel>
Component: WebKit APIAssignee: Fady Samuel <fsamuel>
Status: RESOLVED FIXED    
Severity: Normal CC: aelias, fishd, rjkroege, webkit.review.bot
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 70559    
Attachments:
Description Flags
Patch none

Fady Samuel
Reported 2012-01-31 06:09:58 PST
m_webView->isPageScaleFactorSet() is tested in ChromeClientImpl::layoutUpdated, and it is never true, because WebViewImpl::setPageScaleFactorPreservingScrollOffset is called repeatedly and exits early and thus never calls WebViewImpl::setPageScaleFactor which sets the flag. The simplest solution is to simply get rid of the early return in WebViewImpl::setPageScaleFactorPreservingScrollOffset.
Attachments
Patch (1.92 KB, patch)
2012-01-31 06:30 PST, Fady Samuel
no flags
Fady Samuel
Comment 1 2012-01-31 06:30:24 PST
WebKit Review Bot
Comment 2 2012-01-31 06:32:33 PST
Attachment 124718 [details] did not pass style-queue: Failed to run "['Tools/Scripts/update-webkit']" exit_code: 9 Updating OpenSource From git://git.webkit.org/WebKit baf92d92..7fbc464 master -> origin/master Partial-rebuilding .git/svn/refs/remotes/origin/master/.rev_map.268f45cc-cd09-0410-ab3c-d52691b4dbfc ... Currently at 106356 = baf92d9262faea6b0ee0b2ada47f821fc179c331 r106357 = 7fbc464108a336b4b5cc9d5561e013ca51529334 Done rebuilding .git/svn/refs/remotes/origin/master/.rev_map.268f45cc-cd09-0410-ab3c-d52691b4dbfc First, rewinding head to replay your work on top of it... Applying: Fix compilation errors on build-webkit --debug --no-workers on mac. Using index info to reconstruct a base tree... Falling back to patching base and 3-way merge... Auto-merging LayoutTests/ChangeLog CONFLICT (content): Merge conflict in LayoutTests/ChangeLog Auto-merging LayoutTests/platform/qt/Skipped CONFLICT (content): Merge conflict in LayoutTests/platform/qt/Skipped Auto-merging Source/WebCore/ChangeLog CONFLICT (content): Merge conflict in Source/WebCore/ChangeLog Failed to merge in the changes. Patch failed at 0001 Fix compilation errors on build-webkit --debug --no-workers on mac. When you have resolved this problem run "git rebase --continue". If you would prefer to skip this patch, instead run "git rebase --skip". To restore the original branch and stop rebasing run "git rebase --abort". rebase refs/remotes/origin/master: command returned error: 1 Died at Tools/Scripts/update-webkit line 164. If any of these errors are false positives, please file a bug against check-webkit-style.
Darin Fisher (:fishd, Google)
Comment 3 2012-01-31 13:00:20 PST
Comment on attachment 124718 [details] Patch Is there a way to write a regression test for this bug?
Fady Samuel
Comment 4 2012-01-31 13:27:50 PST
(In reply to comment #3) > (From update of attachment 124718 [details]) > Is there a way to write a regression test for this bug? I'm not sure how, the viewport gets recomputed but nothing changes from the perspective of the webpage so I don't know how to write a layout test for this. The problem is unnecessary work is being done that just burns cycles.
WebKit Review Bot
Comment 5 2012-01-31 14:42:42 PST
Comment on attachment 124718 [details] Patch Clearing flags on attachment: 124718 Committed r106395: <http://trac.webkit.org/changeset/106395>
WebKit Review Bot
Comment 6 2012-01-31 14:42:48 PST
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.