Bug 171503 - Expose viewport-fit instead of clip-to-safe-area
Summary: Expose viewport-fit instead of clip-to-safe-area
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Tim Horton
URL:
Keywords:
Depends on: 171769
Blocks:
  Show dependency treegraph
 
Reported: 2017-05-01 11:53 PDT by Tim Horton
Modified: 2017-05-06 05:20 PDT (History)
8 users (show)

See Also:


Attachments
Patch (81.66 KB, patch)
2017-05-01 11:56 PDT, Tim Horton
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews123 for ios-simulator-wk2 (1.03 MB, application/zip)
2017-05-01 13:43 PDT, Build Bot
no flags Details
Patch (82.56 KB, patch)
2017-05-01 14:19 PDT, Tim Horton
no flags Details | Formatted Diff | Diff
Patch (82.56 KB, patch)
2017-05-01 14:31 PDT, Tim Horton
no flags Details | Formatted Diff | Diff
Patch (83.20 KB, patch)
2017-05-01 14:45 PDT, Tim Horton
no flags Details | Formatted Diff | Diff
Patch (82.79 KB, patch)
2017-05-01 15:07 PDT, Tim Horton
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Horton 2017-05-01 11:53:20 PDT
Expose viewport-fit instead of clip-to-safe-area
Comment 1 Tim Horton 2017-05-01 11:56:50 PDT
Created attachment 308741 [details]
Patch
Comment 2 Build Bot 2017-05-01 12:00:17 PDT
Attachment 308741 [details] did not pass style-queue:


ERROR: Source/WebKit2/Shared/VisibleContentRectUpdateInfo.h:58:  Wrong number of spaces before statement. (expected: 12)  [whitespace/indent] [4]
Total errors found: 1 in 51 files


If any of these errors are false positives, please file a bug against check-webkit-style.
Comment 3 Simon Fraser (smfr) 2017-05-01 12:19:37 PDT
Comment on attachment 308741 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=308741&action=review

> Source/WebCore/dom/ConstantPropertyMap.h:62
> +    void updateConstantsForUnobscuredSafeAreaInsets();

Can this just be updateConstantsForSafeAreaInsets()?

> Source/WebCore/dom/ViewportArguments.h:59
>      float userScalable;
>      float orientation;
>      float shrinkToFit;

I thought you fixed this crazy float stuff earlier?

> Source/WebCore/page/Page.h:335
> +    const FloatBoxExtent& unobscuredSafeAreaInsets() const { return m_unobscuredSafeAreaInsets; }

Can we just call these safeAreaInsets? Does the "unobscured" add anything?

> Source/WebKit2/Shared/mac/RemoteLayerTreeTransaction.h:259
> +    void setAvoidUnsafeArea(bool avoidUnsafeArea) { m_avoidUnsafeArea = avoidUnsafeArea; }

avoids?

> Source/WebKit2/Shared/mac/RemoteLayerTreeTransaction.h:302
> +    bool m_avoidUnsafeArea { true };

avoids?

> Source/WebKit2/UIProcess/PageClient.h:391
> +    virtual void didChangeAvoidUnsafeArea(bool avoidUnsafeArea) = 0;

avoids

> Source/WebKit2/UIProcess/WebPageProxy.h:1204
> +    void setAvoidUnsafeArea(bool);
> +    bool avoidUnsafeArea() const { return m_avoidUnsafeArea; }

avoids

> Source/WebKit2/UIProcess/ios/PageClientImplIOS.h:201
> +    void didChangeAvoidUnsafeArea(bool avoidUnsafeArea) override;

avoids
Comment 4 Tim Horton 2017-05-01 12:21:47 PDT
(In reply to Simon Fraser (smfr) from comment #3)
> Comment on attachment 308741 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=308741&action=review
> 
> > Source/WebCore/dom/ConstantPropertyMap.h:62
> > +    void updateConstantsForUnobscuredSafeAreaInsets();
> 
> Can this just be updateConstantsForSafeAreaInsets()?

Yes.

> > Source/WebCore/dom/ViewportArguments.h:59
> >      float userScalable;
> >      float orientation;
> >      float shrinkToFit;
> 
> I thought you fixed this crazy float stuff earlier?

I only fixed the new one, haven't gone back and fixed the others yet.

> > Source/WebCore/page/Page.h:335
> > +    const FloatBoxExtent& unobscuredSafeAreaInsets() const { return m_unobscuredSafeAreaInsets; }
> 
> Can we just call these safeAreaInsets?

Yes.

> Does the "unobscured" add anything?

Only in my head.

> > Source/WebKit2/Shared/mac/RemoteLayerTreeTransaction.h:259
> > +    void setAvoidUnsafeArea(bool avoidUnsafeArea) { m_avoidUnsafeArea = avoidUnsafeArea; }
> 
> avoids?

Sure.
Comment 5 Build Bot 2017-05-01 13:43:27 PDT
Comment on attachment 308741 [details]
Patch

Attachment 308741 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: http://webkit-queues.webkit.org/results/3652968

New failing tests:
fast/css/variables/constants/ios/safe-area-inset-set.html
Comment 6 Build Bot 2017-05-01 13:43:29 PDT
Created attachment 308761 [details]
Archive of layout-test-results from ews123 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews123  Port: ios-simulator-wk2  Platform: Mac OS X 10.11.6
Comment 7 Tim Horton 2017-05-01 13:58:19 PDT
(In reply to Tim Horton from comment #4)
> (In reply to Simon Fraser (smfr) from comment #3)
> > > Source/WebCore/page/Page.h:335
> > > +    const FloatBoxExtent& unobscuredSafeAreaInsets() const { return m_unobscuredSafeAreaInsets; }
> > 
> > Can we just call these safeAreaInsets?
> 
> Yes.
> 
> > Does the "unobscured" add anything?
> 
> Only in my head.

Actually, I'm going to leave it, for two reasons. I'll draw you pictures later.
Comment 8 Tim Horton 2017-05-01 14:19:07 PDT
Created attachment 308766 [details]
Patch
Comment 9 Tim Horton 2017-05-01 14:31:21 PDT
Created attachment 308768 [details]
Patch
Comment 10 Tim Horton 2017-05-01 14:45:05 PDT
Created attachment 308770 [details]
Patch
Comment 11 Tim Horton 2017-05-01 15:07:27 PDT
Created attachment 308772 [details]
Patch
Comment 12 Csaba Osztrogonác 2017-05-05 23:14:08 PDT
Already landed in https://trac.webkit.org/changeset/216047/webkit
Comment 13 Csaba Osztrogonác 2017-05-06 05:20:10 PDT
and the cmake buildfix landed in https://trac.webkit.org/changeset/216326/webkit