WebKit Bugzilla
Attachment 340043 Details for
Bug 185490
: [Extra zoom mode] fast/viewport/extrazoom/viewport-change-min-device-width.html sometimes fails
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-185490-20180509153514.patch (text/plain), 3.79 KB, created by
Wenson Hsieh
on 2018-05-09 15:35:15 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Wenson Hsieh
Created:
2018-05-09 15:35:15 PDT
Size:
3.79 KB
patch
obsolete
>Subversion Revision: 231537 >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 013a18a36bd2992d4250de8ddfc6b16827bc896d..6ce1bfffdcdbf72d70805cedbc925acd47f836eb 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,28 @@ >+2018-05-09 Wenson Hsieh <wenson_hsieh@apple.com> >+ >+ [Extra zoom mode] fast/viewport/extrazoom/viewport-change-min-device-width.html sometimes fails >+ https://bugs.webkit.org/show_bug.cgi?id=185490 >+ <rdar://problem/40097629> >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ This test is currently flaky due to incorrect logic when computing the unobscured content rect, in the slice of >+ time after a frame load has been committed, and before the first visible content rect update from the UI process >+ after the frame load has been committed. >+ >+ * WebProcess/WebPage/ios/WebPageIOS.mm: >+ (WebKit::WebPage::viewportConfigurationChanged): >+ >+ In the case where !m_hasReceivedVisibleContentRectsAfterDidCommitLoad, we try to set the unobscured content size >+ to be the view size divided by the initial scale. However, in extra zoom mode, `ViewportConfiguration`'s >+ `minimumLayoutSize()` is the layout size, which is larger than the size of the view by default, so dividing this >+ by the initial scale yields a bogus value. Instead, use `viewLayoutSize()` instead. >+ >+ (WebKit::WebPage::updateViewportSizeForCSSViewportUnits): >+ >+ We also try to divide the view size by the initial scale when computing the effective viewport size for `vw` and >+ `vh`. Additionally, fix the misleading name of a variable (largestUnobscuredRect) that stores a size. >+ > 2018-05-08 Sihui Liu <sihui_liu@apple.com> > > Adopt new async _savecookies SPI for keeping networking process active during flushing cookies >diff --git a/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm b/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm >index ff770d667850ad0c44294c745aa73c2ca4fb37f3..e57c86fad372ef0f8babef079c32ad80b1e2e7be 100644 >--- a/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm >+++ b/Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm >@@ -2727,7 +2727,7 @@ void WebPage::viewportConfigurationChanged() > FrameView& frameView = *mainFrameView(); > IntPoint scrollPosition = frameView.scrollPosition(); > if (!m_hasReceivedVisibleContentRectsAfterDidCommitLoad) { >- FloatSize minimumLayoutSizeInScrollViewCoordinates = m_viewportConfiguration.minimumLayoutSize(); >+ FloatSize minimumLayoutSizeInScrollViewCoordinates = m_viewportConfiguration.viewLayoutSize(); > minimumLayoutSizeInScrollViewCoordinates.scale(1 / scale); > IntSize minimumLayoutSizeInDocumentCoordinates = roundedIntSize(minimumLayoutSizeInScrollViewCoordinates); > frameView.setUnobscuredContentSize(minimumLayoutSizeInDocumentCoordinates); >@@ -2749,13 +2749,13 @@ void WebPage::viewportConfigurationChanged() > > void WebPage::updateViewportSizeForCSSViewportUnits() > { >- FloatSize largestUnobscuredRect = m_maximumUnobscuredSize; >- if (largestUnobscuredRect.isEmpty()) >- largestUnobscuredRect = m_viewportConfiguration.minimumLayoutSize(); >+ FloatSize largestUnobscuredSize = m_maximumUnobscuredSize; >+ if (largestUnobscuredSize.isEmpty()) >+ largestUnobscuredSize = m_viewportConfiguration.viewLayoutSize(); > > FrameView& frameView = *mainFrameView(); >- largestUnobscuredRect.scale(1 / m_viewportConfiguration.initialScaleIgnoringContentSize()); >- frameView.setViewportSizeForCSSViewportUnits(roundedIntSize(largestUnobscuredRect)); >+ largestUnobscuredSize.scale(1 / m_viewportConfiguration.initialScaleIgnoringContentSize()); >+ frameView.setViewportSizeForCSSViewportUnits(roundedIntSize(largestUnobscuredSize)); > } > > void WebPage::applicationWillResignActive()
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 185490
: 340043