Bug 145340 - Handle case where -startOptimizedFullscreen fails.
Summary: Handle case where -startOptimizedFullscreen fails.
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Media (show other bugs)
Version: 528+ (Nightly build)
Hardware: iPhone / iPad Unspecified
: P2 Normal
Assignee: Jeremy Jones
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-05-22 22:20 PDT by Jeremy Jones
Modified: 2015-05-27 10:12 PDT (History)
1 user (show)

See Also:


Attachments
Patch (8.85 KB, patch)
2015-05-22 22:28 PDT, Jeremy Jones
no flags Details | Formatted Diff | Diff
Patch (8.98 KB, patch)
2015-05-24 10:18 PDT, Jeremy Jones
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jeremy Jones 2015-05-22 22:20:43 PDT
Handle case where -startOptimizedFullscreen fails.
Comment 1 Jeremy Jones 2015-05-22 22:21:18 PDT
rdar://problem/19416954
Comment 2 Jeremy Jones 2015-05-22 22:28:39 PDT
Created attachment 253638 [details]
Patch
Comment 3 Eric Carlson 2015-05-24 08:40:39 PDT
Comment on attachment 253638 [details]
Patch

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

> Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm:1291
> +    RefPtr<WebVideoFullscreenInterfaceAVKit> strongThis(this);
> +    WebThreadRun([strongThis, this] {
> +        if (hasMode(HTMLMediaElementEnums::VideoFullscreenModeStandard))
> +            return;
> +
> +        m_exitCompleted = true;

This will leave m_exitCompleted set to true if hasMode(HTMLMediaElementEnums::VideoFullscreenModeStandard). Will this cause problems later?
Comment 4 Jeremy Jones 2015-05-24 10:00:09 PDT
(In reply to comment #3)
> Comment on attachment 253638 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=253638&action=review
> 
> > Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm:1291
> > +    RefPtr<WebVideoFullscreenInterfaceAVKit> strongThis(this);
> > +    WebThreadRun([strongThis, this] {
> > +        if (hasMode(HTMLMediaElementEnums::VideoFullscreenModeStandard))
> > +            return;
> > +
> > +        m_exitCompleted = true;
> 
> This will leave m_exitCompleted set to true if
> hasMode(HTMLMediaElementEnums::VideoFullscreenModeStandard). Will this cause
> problems later?

I think you mean leave it false. And that is exactly what we want. If we still have standard mode, then we have not completely exited fullscreen.

Also, the build error is SPI that I'll add to AVKitSPI.h
Comment 5 Jeremy Jones 2015-05-24 10:18:58 PDT
Created attachment 253658 [details]
Patch
Comment 6 WebKit Commit Bot 2015-05-27 10:12:32 PDT
Comment on attachment 253658 [details]
Patch

Clearing flags on attachment: 253658

Committed r184907: <http://trac.webkit.org/changeset/184907>
Comment 7 WebKit Commit Bot 2015-05-27 10:12:35 PDT
All reviewed patches have been landed.  Closing bug.