Bug 59147

Summary: Disable MediaPlayerPrivateAVFoundation when using old full screen mode.
Product: WebKit Reporter: Jer Noble <jer.noble>
Component: MediaAssignee: Jer Noble <jer.noble>
Status: RESOLVED FIXED    
Severity: Normal CC: eric.carlson
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.6   
Bug Depends on:    
Bug Blocks: 59179    
Attachments:
Description Flags
Patch mjs: review+

Description Jer Noble 2011-04-21 15:17:38 PDT
If the ChromeClient indicates the client supports the old full screen mode, but does not support the new full screen mode, disable AVFoundation playback, so that full screen mode continues to work.
Comment 1 Jer Noble 2011-04-21 15:18:01 PDT
<rdar://problem/9320415>
Comment 2 Jer Noble 2011-04-22 00:49:56 PDT
Created attachment 90676 [details]
Patch
Comment 3 Maciej Stachowiak 2011-04-22 01:36:38 PDT
Comment on attachment 90676 [details]
Patch

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

> Source/WebKit/mac/WebView/WebView.mm:1565
> +#if ENABLE(FULLSCREEN_API)
> +    if (![preferences fullScreenEnabled])
> +        settings->setAVFoundationEnabled(false);
> +    else
> +#endif

I'm not sure I understand the logic here. If the full screen API is compiled in, and a client doesn't have it enabled, then we force AVFoundation off. But if fullscreen API wasn't compiled in at all, wouldn't we still want AVFoundation turned off? This probably doesn't matter, since we won't actually face that combination of settings.
Comment 4 Jer Noble 2011-04-22 01:42:45 PDT
(In reply to comment #3)
> (From update of attachment 90676 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=90676&action=review
> 
> > Source/WebKit/mac/WebView/WebView.mm:1565
> > +#if ENABLE(FULLSCREEN_API)
> > +    if (![preferences fullScreenEnabled])
> > +        settings->setAVFoundationEnabled(false);
> > +    else
> > +#endif
> 
> I'm not sure I understand the logic here. If the full screen API is compiled in, and a client doesn't have it enabled, then we force AVFoundation off. But if fullscreen API wasn't compiled in at all, wouldn't we still want AVFoundation turned off? This probably doesn't matter, since we won't actually face that combination of settings.

That's a good point.  I'll refactor this part so that AVFoundation gets disabled if FULLSCREEN_API is turned off.
Comment 5 Jer Noble 2011-04-22 10:51:23 PDT
Committed r84646: <http://trac.webkit.org/changeset/84646>