summaryrefslogtreecommitdiffstats
path: root/content/browser/android/browser_startup_controller.cc
diff options
context:
space:
mode:
authorkuan@chromium.org <kuan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-18 14:26:11 +0000
committerkuan@chromium.org <kuan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-18 14:26:11 +0000
commit2ba6b280791983324c24dbef211fd4db97ad7f55 (patch)
tree8f30deeb3854e9ffb2025f253e6c366298dbf5db /content/browser/android/browser_startup_controller.cc
parentdb16bf7f976cca1ca38b3249353cff4a006dcf90 (diff)
downloadchromium_src-2ba6b280791983324c24dbef211fd4db97ad7f55.zip
chromium_src-2ba6b280791983324c24dbef211fd4db97ad7f55.tar.gz
chromium_src-2ba6b280791983324c24dbef211fd4db97ad7f55.tar.bz2
DomDistiller: fix 0 document width
bug: When distilling a page with new WebContents, document.offsetWidth in domdistiller.js is always 0, because the newly created RenderView doesn't have a size. fix: DistillerPageWebContents extends WebContentsDelegate and implements GetNewSizeForRenderView() to return the size for the new RenderView. This size is the container bounds of the WebContents from where the distillation is triggered. The size is plumbed through the pipeline from the following sources all the way down to DistillerPageWebContents. 1) WebUI: WebContents of chrome:://dom-distiller 3) ReadingList: WebContents currently associated with the extension 2) standalone ContentExtractor: WebContents of content::Shell As for the reused WebContents (via "Distill page" in wrench menu), it already has a size, so we just use it. BUG=368941,367254 TBR=danakj (ui/gfx/size.h) Review URL: https://codereview.chromium.org/396503003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@284094 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/browser/android/browser_startup_controller.cc')
0 files changed, 0 insertions, 0 deletions