RESOLVED FIXED 194892
scalableNativeWebpageParameters() is not preserved on new page navigation.
https://bugs.webkit.org/show_bug.cgi?id=194892
Summary scalableNativeWebpageParameters() is not preserved on new page navigation.
Yongjun Zhang
Reported 2019-02-20 19:41:05 PST
If a page's current default viewport configuration is scalableNativeWebpageParameters, loading a new page should preserve this configuration.
Attachments
Patch (16.43 KB, patch)
2019-02-20 20:55 PST, Yongjun Zhang
no flags
Fix Mac build break. (16.43 KB, patch)
2019-02-20 22:32 PST, Yongjun Zhang
ews-watchlist: commit-queue-
Archive of layout-test-results from ews124 for ios-simulator-wk2 (2.57 MB, application/zip)
2019-02-21 00:24 PST, EWS Watchlist
no flags
Fix DRT build break. (18.93 KB, patch)
2019-02-21 10:46 PST, Yongjun Zhang
ews-watchlist: commit-queue-
Archive of layout-test-results from ews125 for ios-simulator-wk2 (2.48 MB, application/zip)
2019-02-21 12:47 PST, EWS Watchlist
no flags
Fix a failed layout test. (16.63 KB, patch)
2019-02-21 14:05 PST, Yongjun Zhang
ews-watchlist: commit-queue-
Archive of layout-test-results from ews124 for ios-simulator-wk2 (2.54 MB, application/zip)
2019-02-21 16:39 PST, EWS Watchlist
no flags
Fix a failed layout test again. (17.67 KB, patch)
2019-02-22 15:06 PST, Yongjun Zhang
wenson_hsieh: review+
Address review comments and commit. (18.06 KB, patch)
2019-02-25 19:58 PST, Yongjun Zhang
no flags
Yongjun Zhang
Comment 1 2019-02-20 19:44:35 PST
Yongjun Zhang
Comment 2 2019-02-20 20:55:42 PST
Yongjun Zhang
Comment 3 2019-02-20 22:32:09 PST
Created attachment 362594 [details] Fix Mac build break.
EWS Watchlist
Comment 4 2019-02-21 00:24:04 PST
Comment on attachment 362594 [details] Fix Mac build break. Attachment 362594 [details] did not pass ios-sim-ews (ios-simulator-wk2): Output: https://webkit-queues.webkit.org/results/11229089 New failing tests: fast/viewport/ios/minimum-scale-after-changing-view-scale.html
EWS Watchlist
Comment 5 2019-02-21 00:24:06 PST
Created attachment 362598 [details] Archive of layout-test-results from ews124 for ios-simulator-wk2 The attached test failures were seen while running run-webkit-tests on the ios-sim-ews. Bot: ews124 Port: ios-simulator-wk2 Platform: Mac OS X 10.13.6
Yongjun Zhang
Comment 6 2019-02-21 10:46:38 PST
Created attachment 362619 [details] Fix DRT build break.
EWS Watchlist
Comment 7 2019-02-21 12:47:25 PST
Comment on attachment 362619 [details] Fix DRT build break. Attachment 362619 [details] did not pass ios-sim-ews (ios-simulator-wk2): Output: https://webkit-queues.webkit.org/results/11234456 New failing tests: fast/viewport/ios/preserve-viewport-shrink-to-fit-on-new-navigation.html fast/viewport/ios/minimum-scale-after-changing-view-scale.html
EWS Watchlist
Comment 8 2019-02-21 12:47:27 PST
Created attachment 362630 [details] Archive of layout-test-results from ews125 for ios-simulator-wk2 The attached test failures were seen while running run-webkit-tests on the ios-sim-ews. Bot: ews125 Port: ios-simulator-wk2 Platform: Mac OS X 10.13.6
Yongjun Zhang
Comment 9 2019-02-21 14:05:00 PST
Created attachment 362642 [details] Fix a failed layout test.
EWS Watchlist
Comment 10 2019-02-21 16:39:19 PST
Comment on attachment 362642 [details] Fix a failed layout test. Attachment 362642 [details] did not pass ios-sim-ews (ios-simulator-wk2): Output: https://webkit-queues.webkit.org/results/11237861 New failing tests: fast/viewport/ios/minimum-scale-after-changing-view-scale.html
EWS Watchlist
Comment 11 2019-02-21 16:39:21 PST
Created attachment 362670 [details] Archive of layout-test-results from ews124 for ios-simulator-wk2 The attached test failures were seen while running run-webkit-tests on the ios-sim-ews. Bot: ews124 Port: ios-simulator-wk2 Platform: Mac OS X 10.13.6
Yongjun Zhang
Comment 12 2019-02-22 15:06:34 PST
Created attachment 362768 [details] Fix a failed layout test again.
Wenson Hsieh
Comment 13 2019-02-25 14:53:18 PST
Comment on attachment 362768 [details] Fix a failed layout test again. View in context: https://bugs.webkit.org/attachment.cgi?id=362768&action=review > Source/WebCore/page/ViewportConfiguration.cpp:336 > +ViewportConfiguration::Parameters ViewportConfiguration::fixedNativeWebpageParameters() It's somewhat confusing that nativeWebpageParameters splits off into scalableNativeWebpageParameters or fixedNativeWebpageParameters. I think fixedNativeWebpageParameters is a bit of a strange name too (the key point here is that the fixed parameters don't allow shrink to fit, right?) Maybe we can make this more explicit, like... nativeWebpageParameters() returns either nativeWebpageParametersWithShrinkToFit() or nativeWebpageParametersWithoutShrinkToFit()? > Tools/WebKitTestRunner/UIScriptControllerCocoa.mm:60 > + TestController::singleton().mainWebView()->platformView()._allowsViewportShrinkToFit = allows; Nit - I think you could just put this in UIScriptControllerIOS.mm, since _allowsViewportShrinkToFit is only available on iOS.
Yongjun Zhang
Comment 14 2019-02-25 17:06:32 PST
(In reply to Wenson Hsieh from comment #13) > Comment on attachment 362768 [details] > Fix a failed layout test again. > > View in context: > https://bugs.webkit.org/attachment.cgi?id=362768&action=review > > > Source/WebCore/page/ViewportConfiguration.cpp:336 > > +ViewportConfiguration::Parameters ViewportConfiguration::fixedNativeWebpageParameters() > > It's somewhat confusing that nativeWebpageParameters splits off into > scalableNativeWebpageParameters or fixedNativeWebpageParameters. I think > fixedNativeWebpageParameters is a bit of a strange name too (the key point > here is that the fixed parameters don't allow shrink to fit, right?) > > Maybe we can make this more explicit, like... > > nativeWebpageParameters() returns either > nativeWebpageParametersWithShrinkToFit() or > nativeWebpageParametersWithoutShrinkToFit()? > Good point! Will change. > > Tools/WebKitTestRunner/UIScriptControllerCocoa.mm:60 > > + TestController::singleton().mainWebView()->platformView()._allowsViewportShrinkToFit = allows; > > Nit - I think you could just put this in UIScriptControllerIOS.mm, since > _allowsViewportShrinkToFit is only available on iOS.
Yongjun Zhang
Comment 15 2019-02-25 19:58:06 PST
Created attachment 362953 [details] Address review comments and commit.
WebKit Commit Bot
Comment 16 2019-02-25 20:38:05 PST
Comment on attachment 362953 [details] Address review comments and commit. Clearing flags on attachment: 362953 Committed r242069: <https://trac.webkit.org/changeset/242069>
WebKit Commit Bot
Comment 17 2019-02-25 20:38:06 PST
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 18 2019-02-25 20:39:31 PST
Note You need to log in before you can comment on or make changes to this bug.