Bug 207406

Summary: [iOS] Check if PIP is supported in the UI process
Product: WebKit Reporter: Per Arne Vollan <pvollan>
Component: WebKit Misc.Assignee: Per Arne Vollan <pvollan>
Status: RESOLVED FIXED    
Severity: Normal CC: bfulgham, commit-queue, eric.carlson, ews-watchlist, ggaren, glenn, jer.noble, peng.liu6, philipj, sergio, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch none

Description Per Arne Vollan 2020-02-07 14:07:20 PST
This is currently being checked in the WebProcess, but since this check is initiating communication with the frontboard service which will be blocked, this check should be moved to the UI process.
Comment 1 Per Arne Vollan 2020-02-07 14:27:27 PST
Created attachment 390123 [details]
Patch
Comment 2 Per Arne Vollan 2020-02-07 15:14:10 PST
Created attachment 390133 [details]
Patch
Comment 3 Peng Liu 2020-02-07 16:49:50 PST
Comment on attachment 390133 [details]
Patch

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

> Source/WebCore/testing/Internals.cpp:5472
> +#if PLATFORM(IOS_FAMILY)

We need to check the support for Mac as well.
Comment 4 Per Arne Vollan 2020-02-07 16:51:33 PST
(In reply to Peng Liu from comment #3)
> Comment on attachment 390133 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=390133&action=review
> 
> > Source/WebCore/testing/Internals.cpp:5472
> > +#if PLATFORM(IOS_FAMILY)
> 
> We need to check the support for Mac as well.

I will include that. Thanks for reviewing!
Comment 5 Per Arne Vollan 2020-02-10 10:45:38 PST
Created attachment 390264 [details]
Patch
Comment 6 Brent Fulgham 2020-02-13 11:02:53 PST
Comment on attachment 390264 [details]
Patch

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

Looks good. r=me

> Source/WebCore/ChangeLog:11
> +        WebContent is storing the received value.

We have PIP in macOS, but I guess we don't do this check there?

Are there macOS changes we should plan as well?
Comment 7 Per Arne Vollan 2020-02-13 11:21:57 PST
(In reply to Brent Fulgham from comment #6)
> Comment on attachment 390264 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=390264&action=review
> 
> Looks good. r=me
> 
> > Source/WebCore/ChangeLog:11
> > +        WebContent is storing the received value.
> 
> We have PIP in macOS, but I guess we don't do this check there?
> 
> Are there macOS changes we should plan as well?

Yes, you are right. There is some additional macOS work required, since macOS does not have the same setting/notification.

Thanks for reviewing!
Comment 8 Per Arne Vollan 2020-02-13 11:27:01 PST
(In reply to Per Arne Vollan from comment #7)
> (In reply to Brent Fulgham from comment #6)
> > Comment on attachment 390264 [details]
> > Patch
> > 
> > View in context:
> > https://bugs.webkit.org/attachment.cgi?id=390264&action=review
> > 
> > Looks good. r=me
> > 
> > > Source/WebCore/ChangeLog:11
> > > +        WebContent is storing the received value.
> > 
> > We have PIP in macOS, but I guess we don't do this check there?
> > 
> > Are there macOS changes we should plan as well?
> 
> Yes, you are right. There is some additional macOS work required, since
> macOS does not have the same setting/notification.
> 

Sorry, I was thinking of another issue when making this comment. On macOS, we probably don't connect to the same service when checking whether PiP is enabled, but as you suggest, we should look into the issue on macOS as well, in order to determine which service is being used there.
Comment 9 WebKit Commit Bot 2020-02-13 12:21:30 PST
The commit-queue encountered the following flaky tests while processing attachment 390264 [details]:

editing/spelling/spellcheck-attribute.html bug 206178 (authors: g.czajkowski@samsung.com, mark.lam@apple.com, and rniwa@webkit.org)
The commit-queue is continuing to process your patch.
Comment 10 WebKit Commit Bot 2020-02-13 12:22:10 PST
Comment on attachment 390264 [details]
Patch

Clearing flags on attachment: 390264

Committed r256531: <https://trac.webkit.org/changeset/256531>
Comment 11 WebKit Commit Bot 2020-02-13 12:22:12 PST
All reviewed patches have been landed.  Closing bug.
Comment 12 Radar WebKit Bug Importer 2020-02-13 12:23:16 PST
<rdar://problem/59433043>