<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[163600] trunk/Source</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/163600">163600</a></dd>
<dt>Author</dt> <dd>commit-queue@webkit.org</dd>
<dt>Date</dt> <dd>2014-02-06 18:19:55 -0800 (Thu, 06 Feb 2014)</dd>
</dl>
<h3>Log Message</h3>
<pre>Add support for AVKit fullscreen to WebKit2
https://bugs.webkit.org/show_bug.cgi?id=128143
Patch by Jeremy Jones <jeremyj@apple.com> on 2014-02-06
Reviewed by Simon Fraser.
Source/WebCore:
Rename overloaded functions to prevent ambiguous template parameter
compile error in generated code.
Rename overloaded exitFullscreen to exitFullscreenWithCompletionHandler.
Rename overloaded enterFullscreen to enterFullscreenWithCompletionHandler.
* WebCore.exp.in:
* WebCore.xcodeproj/project.pbxproj:
* platform/ios/WebVideoFullscreenControllerAVKit.mm:
(-[WebVideoFullscreenController exitFullscreen]):
* platform/ios/WebVideoFullscreenInterfaceAVKit.h:
* platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
(WebVideoFullscreenInterfaceAVKit::enterFullscreenWithCompletionHandler):
(WebVideoFullscreenInterfaceAVKit::enterFullscreen):
(WebVideoFullscreenInterfaceAVKit::exitFullscreenWithCompletionHandler):
(WebVideoFullscreenInterfaceAVKit::exitFullscreen):
* platform/ios/WebVideoFullscreenModelMediaElement.h:
Source/WebKit2:
Add WebVideoFullscreenManager and WebVideoFullscreenManagerProxy that implement
WebVideoFullscreenModel and WebVideoFullscreenInterface.
* DerivedSources.make:
* UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::WebPageProxy):
initialize member m_videoFullscreenManager
(WebKit::WebPageProxy::videoFullscreenManager):
add accessor for videoFullscreenManager
* UIProcess/WebPageProxy.h:
* UIProcess/WebVideoFullscreenManagerProxy.cpp: Added.
(WebKit::WebVideoFullscreenManagerProxy::create):
(WebKit::WebVideoFullscreenManagerProxy::WebVideoFullscreenManagerProxy):
(WebKit::WebVideoFullscreenManagerProxy::~WebVideoFullscreenManagerProxy):
add basic creation for object.
(WebKit::WebVideoFullscreenManagerProxy::setVideoLayerID):
(WebKit::WebVideoFullscreenManagerProxy::requestExitFullScreen):
(WebKit::WebVideoFullscreenManagerProxy::play):
(WebKit::WebVideoFullscreenManagerProxy::pause):
(WebKit::WebVideoFullscreenManagerProxy::togglePlayState):
(WebKit::WebVideoFullscreenManagerProxy::seekToTime):
(WebKit::WebVideoFullscreenManagerProxy::didExitFullscreen):
implement WebVideoFullscreenModel to send IPC message.
* UIProcess/WebVideoFullscreenManagerProxy.h: Added.
* UIProcess/WebVideoFullscreenManagerProxy.messages.in: Added.
this interface closely matches WebVideoFullscreenInterface
* WebKit2.xcodeproj/project.pbxproj:
* WebProcess/WebCoreSupport/WebChromeClient.cpp:
(WebKit::WebChromeClient::supportsFullscreenForNode):
(WebKit::WebChromeClient::enterFullscreenForNode):
(WebKit::WebChromeClient::exitFullscreenForNode):
Forward these requests onto the videoFullscreenManager
* WebProcess/WebCoreSupport/WebChromeClient.h:
* WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::videoFullscreenManager):
accessor for m_videoFullscreenManager
* WebProcess/WebPage/WebPage.h:
* WebProcess/WebVideoFullscreenManager.cpp: Added.
(WebKit::WebVideoFullscreenManager::create):
(WebKit::WebVideoFullscreenManager::WebVideoFullscreenManager):
(WebKit::WebVideoFullscreenManager::~WebVideoFullscreenManager):
add basic creation for object.
(WebKit::WebVideoFullscreenManager::supportsFullscreen):
(WebKit::WebVideoFullscreenManager::enterFullscreenForNode):
(WebKit::WebVideoFullscreenManager::exitFullscreenForNode):
implement interface called by WebChromeClient
(WebKit::WebVideoFullscreenManager::setDuration):
(WebKit::WebVideoFullscreenManager::setCurrentTime):
(WebKit::WebVideoFullscreenManager::setRate):
(WebKit::WebVideoFullscreenManager::setVideoDimensions):
(WebKit::WebVideoFullscreenManager::setVideoLayer):
(WebKit::WebVideoFullscreenManager::setVideoLayerID):
(WebKit::WebVideoFullscreenManager::enterFullscreen):
(WebKit::WebVideoFullscreenManager::exitFullscreen):
implement WebVideoFullscreenInterface to send IPC message.
* WebProcess/WebVideoFullscreenManager.h: Added.
* WebProcess/WebVideoFullscreenManager.messages.in: Added.
this interface closely matches WebVideoFullscreenModel</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#trunkSourceWebCoreChangeLog">trunk/Source/WebCore/ChangeLog</a></li>
<li><a href="#trunkSourceWebCoreWebCoreexpin">trunk/Source/WebCore/WebCore.exp.in</a></li>
<li><a href="#trunkSourceWebCoreWebCorexcodeprojprojectpbxproj">trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebCoreplatformiosWebVideoFullscreenControllerAVKitmm">trunk/Source/WebCore/platform/ios/WebVideoFullscreenControllerAVKit.mm</a></li>
<li><a href="#trunkSourceWebCoreplatformiosWebVideoFullscreenInterfaceAVKith">trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.h</a></li>
<li><a href="#trunkSourceWebCoreplatformiosWebVideoFullscreenInterfaceAVKitmm">trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm</a></li>
<li><a href="#trunkSourceWebCoreplatformiosWebVideoFullscreenModelMediaElementh">trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.h</a></li>
<li><a href="#trunkSourceWebCoreplatformiosWebVideoFullscreenModelMediaElementmm">trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.mm</a></li>
<li><a href="#trunkSourceWebKit2ChangeLog">trunk/Source/WebKit2/ChangeLog</a></li>
<li><a href="#trunkSourceWebKit2DerivedSourcesmake">trunk/Source/WebKit2/DerivedSources.make</a></li>
<li><a href="#trunkSourceWebKit2UIProcessWebPageProxycpp">trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp</a></li>
<li><a href="#trunkSourceWebKit2UIProcessWebPageProxyh">trunk/Source/WebKit2/UIProcess/WebPageProxy.h</a></li>
<li><a href="#trunkSourceWebKit2WebKit2xcodeprojprojectpbxproj">trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebChromeClientcpp">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebCoreSupportWebChromeClienth">trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebPageWebPagecpp">trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessWebPageWebPageh">trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h</a></li>
</ul>
<h3>Added Paths</h3>
<ul>
<li><a href="#trunkSourceWebKit2UIProcessiosWebVideoFullscreenManagerProxycpp">trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.cpp</a></li>
<li><a href="#trunkSourceWebKit2UIProcessiosWebVideoFullscreenManagerProxyh">trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.h</a></li>
<li><a href="#trunkSourceWebKit2UIProcessiosWebVideoFullscreenManagerProxymessagesin">trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in</a></li>
<li><a href="#trunkSourceWebKit2WebProcessiosWebVideoFullscreenManagercpp">trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.cpp</a></li>
<li><a href="#trunkSourceWebKit2WebProcessiosWebVideoFullscreenManagerh">trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.h</a></li>
<li><a href="#trunkSourceWebKit2WebProcessiosWebVideoFullscreenManagermessagesin">trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.messages.in</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunkSourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/ChangeLog (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/ChangeLog        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/ChangeLog        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -1,3 +1,28 @@
</span><ins>+2014-02-06 Jeremy Jones <jeremyj@apple.com>
+
+ Add support for AVKit fullscreen to WebKit2
+ https://bugs.webkit.org/show_bug.cgi?id=128143
+
+ Reviewed by Simon Fraser.
+
+ Rename overloaded functions to prevent ambiguous template parameter
+ compile error in generated code.
+
+ Rename overloaded exitFullscreen to exitFullscreenWithCompletionHandler.
+ Rename overloaded enterFullscreen to enterFullscreenWithCompletionHandler.
+
+ * WebCore.exp.in:
+ * WebCore.xcodeproj/project.pbxproj:
+ * platform/ios/WebVideoFullscreenControllerAVKit.mm:
+ (-[WebVideoFullscreenController exitFullscreen]):
+ * platform/ios/WebVideoFullscreenInterfaceAVKit.h:
+ * platform/ios/WebVideoFullscreenInterfaceAVKit.mm:
+ (WebVideoFullscreenInterfaceAVKit::enterFullscreenWithCompletionHandler):
+ (WebVideoFullscreenInterfaceAVKit::enterFullscreen):
+ (WebVideoFullscreenInterfaceAVKit::exitFullscreenWithCompletionHandler):
+ (WebVideoFullscreenInterfaceAVKit::exitFullscreen):
+ * platform/ios/WebVideoFullscreenModelMediaElement.h:
+
</ins><span class="cx"> 2014-02-06 Jeffrey Pfau <jpfau@apple.com>
</span><span class="cx">
</span><span class="cx"> loadSubframe can return null in SubframeLoader::loadOrRedirectSubframe
</span></span></pre></div>
<a id="trunkSourceWebCoreWebCoreexpin"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/WebCore.exp.in (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/WebCore.exp.in        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/WebCore.exp.in        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -3053,36 +3053,62 @@
</span><span class="cx"> #endif
</span><span class="cx">
</span><span class="cx"> #if ENABLE(VIDEO)
</span><ins>+.objc_class_name_WebVideoFullscreenController
+__ZN7WebCore10TimeRanges3addEdd
+__ZN7WebCore12toTimeRangesEN3JSC7JSValueE
</ins><span class="cx"> __ZN7WebCore16HTMLMediaElement12endScrubbingEv
</span><span class="cx"> __ZN7WebCore16HTMLMediaElement14beginScrubbingEv
</span><span class="cx"> __ZN7WebCore16HTMLMediaElement14exitFullscreenEv
</span><span class="cx"> __ZN7WebCore16HTMLMediaElement15clearMediaCacheEv
</span><ins>+__ZN7WebCore16HTMLMediaElement15togglePlayStateEv
+__ZN7WebCore16HTMLMediaElement16returnToRealtimeEv
</ins><span class="cx"> __ZN7WebCore16HTMLMediaElement20getSitesInMediaCacheERN3WTF6VectorINS1_6StringELm0ENS1_15CrashOnOverflowEEE
</span><span class="cx"> __ZN7WebCore16HTMLMediaElement22clearMediaCacheForSiteERKN3WTF6StringE
</span><span class="cx"> __ZN7WebCore16HTMLMediaElement4playEv
</span><span class="cx"> __ZN7WebCore16HTMLMediaElement5pauseEv
</span><span class="cx"> __ZN7WebCore16HTMLMediaElement8setMutedEb
</span><ins>+__ZN7WebCore4toJSEPN3JSC9ExecStateEPNS_17JSDOMGlobalObjectEPNS_10TimeRangesE
+__ZNK7WebCore10TimeRanges7nearestEd
</ins><span class="cx"> __ZNK7WebCore16HTMLMediaElement11currentTimeEv
</span><ins>+__ZNK7WebCore16HTMLMediaElement12isFullscreenEv
+__ZNK7WebCore16HTMLMediaElement12playbackRateEv
</ins><span class="cx"> __ZNK7WebCore16HTMLMediaElement13platformMediaEv
</span><ins>+__ZNK7WebCore16HTMLMediaElement5endedEv
</ins><span class="cx"> __ZNK7WebCore16HTMLMediaElement5mutedEv
</span><ins>+__ZNK7WebCore16HTMLMediaElement6pausedEv
</ins><span class="cx"> __ZNK7WebCore16HTMLMediaElement6volumeEv
</span><span class="cx"> __ZNK7WebCore16HTMLMediaElement7canPlayEv
</span><del>-__ZNK7WebCore16HTMLMediaElement12playbackRateEv
</del><span class="cx"> __ZNK7WebCore16HTMLMediaElement8durationEv
</span><del>-__ZN7WebCore16HTMLMediaElement16returnToRealtimeEv
-__ZNK7WebCore16HTMLMediaElement12isFullscreenEv
-__ZN7WebCore10TimeRanges3addEdd
-__ZN7WebCore12toTimeRangesEN3JSC7JSValueE
-__ZN7WebCore4toJSEPN3JSC9ExecStateEPNS_17JSDOMGlobalObjectEPNS_10TimeRangesE
-__ZNK7WebCore10TimeRanges7nearestEd
</del><span class="cx"> #endif
</span><span class="cx">
</span><del>-#if ENABLE(VIDEO)
-__ZNK7WebCore16HTMLMediaElement5endedEv
-__ZNK7WebCore16HTMLMediaElement6pausedEv
-.objc_class_name_WebVideoFullscreenController
</del><ins>+#if ENABLE(VIDEO) && PLATFORM(IOS)
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit11setDurationEd
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit13setVideoLayerEP7CALayer
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit14exitFullscreenEv
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit14setCurrentTimeEdd
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit15enterFullscreenEv
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit18setVideoDimensionsEbff
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit26setWebVideoFullscreenModelEPNS_23WebVideoFullscreenModelE
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKit7setRateEbf
+__ZN7WebCore32WebVideoFullscreenInterfaceAVKitC2Ev
+__ZN7WebCore35WebVideoFullscreenModelMediaElement10seekToTimeEd
+__ZN7WebCore35WebVideoFullscreenModelMediaElement11handleEventEPNS_22ScriptExecutionContextEPNS_5EventE
+__ZN7WebCore35WebVideoFullscreenModelMediaElement15setMediaElementEPNS_16HTMLMediaElementE
+__ZN7WebCore35WebVideoFullscreenModelMediaElement15togglePlayStateEv
+__ZN7WebCore35WebVideoFullscreenModelMediaElement17didExitFullscreenEv
+__ZN7WebCore35WebVideoFullscreenModelMediaElement21requestExitFullScreenEv
+__ZN7WebCore35WebVideoFullscreenModelMediaElement4playEv
+__ZN7WebCore35WebVideoFullscreenModelMediaElement5pauseEv
+__ZN7WebCore35WebVideoFullscreenModelMediaElementC2Ev
+__ZN7WebCore35WebVideoFullscreenModelMediaElementD2Ev
+__ZNK7WebCore16HTMLVideoElement10videoWidthEv
+__ZNK7WebCore16HTMLVideoElement11videoHeightEv
+__ZTVN7WebCore32WebVideoFullscreenInterfaceAVKitE
+__ZTVN7WebCore35WebVideoFullscreenModelMediaElementE
+__ZThn8_N7WebCore35WebVideoFullscreenModelMediaElement11handleEventEPNS_22ScriptExecutionContextEPNS_5EventE
</ins><span class="cx"> #endif
</span><span class="cx">
</span><ins>+
</ins><span class="cx"> #if ENABLE(VIEW_MODE_CSS_MEDIA)
</span><span class="cx"> __ZN7WebCore4Page11setViewModeENS0_8ViewModeE
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="trunkSourceWebCoreWebCorexcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -5903,7 +5903,7 @@
</span><span class="cx">                 E44613A70CD6331000FADA75 /* HTMLSourceElement.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E44613950CD6331000FADA75 /* HTMLSourceElement.cpp */; };
</span><span class="cx">                 E44613A80CD6331000FADA75 /* HTMLSourceElement.h in Headers */ = {isa = PBXBuildFile; fileRef = E44613960CD6331000FADA75 /* HTMLSourceElement.h */; };
</span><span class="cx">                 E44613AA0CD6331000FADA75 /* HTMLVideoElement.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E44613980CD6331000FADA75 /* HTMLVideoElement.cpp */; };
</span><del>-                E44613AB0CD6331000FADA75 /* HTMLVideoElement.h in Headers */ = {isa = PBXBuildFile; fileRef = E44613990CD6331000FADA75 /* HTMLVideoElement.h */; };
</del><ins>+                E44613AB0CD6331000FADA75 /* HTMLVideoElement.h in Headers */ = {isa = PBXBuildFile; fileRef = E44613990CD6331000FADA75 /* HTMLVideoElement.h */; settings = {ATTRIBUTES = (Private, ); }; };
</ins><span class="cx">                 E44613AD0CD6331000FADA75 /* MediaError.h in Headers */ = {isa = PBXBuildFile; fileRef = E446139B0CD6331000FADA75 /* MediaError.h */; };
</span><span class="cx">                 E44613AF0CD6331000FADA75 /* TimeRanges.cpp in Sources */ = {isa = PBXBuildFile; fileRef = E446139D0CD6331000FADA75 /* TimeRanges.cpp */; };
</span><span class="cx">                 E44613B00CD6331000FADA75 /* TimeRanges.h in Headers */ = {isa = PBXBuildFile; fileRef = E446139E0CD6331000FADA75 /* TimeRanges.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformiosWebVideoFullscreenControllerAVKitmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/ios/WebVideoFullscreenControllerAVKit.mm (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/ios/WebVideoFullscreenControllerAVKit.mm        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/platform/ios/WebVideoFullscreenControllerAVKit.mm        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -82,7 +82,7 @@
</span><span class="cx"> {
</span><span class="cx"> RetainPtr<WebVideoFullscreenController> strongSelf(self);
</span><span class="cx">
</span><del>- _interface->exitFullscreen([strongSelf]{
</del><ins>+ _interface->exitFullscreenWithCompletionHandler([strongSelf]{
</ins><span class="cx"> WebThreadRun([strongSelf]{
</span><span class="cx"> strongSelf->_model->setMediaElement(nullptr);
</span><span class="cx"> strongSelf->_interface->setWebVideoFullscreenModel(nullptr);
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformiosWebVideoFullscreenInterfaceAVKith"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.h (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.h        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.h        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -64,11 +64,11 @@
</span><span class="cx"> void setRate(bool isPlaying, float playbackRate) override;
</span><span class="cx"> void setVideoDimensions(bool hasVideo, float width, float height) override;
</span><span class="cx"> void setVideoLayer(PlatformLayer*) override;
</span><del>- void setVideoLayerID(uint32_t videoContextID) override {UNUSED_PARAM(videoContextID);};
</del><ins>+ void setVideoLayerID(uint32_t) override { };
</ins><span class="cx"> void enterFullscreen() override;
</span><del>- void enterFullscreen(std::function<void()> completion);
</del><ins>+ void enterFullscreenWithCompletionHandler(std::function<void()>);
</ins><span class="cx"> void exitFullscreen() override;
</span><del>- void exitFullscreen(std::function<void()> completion);
</del><ins>+ void exitFullscreenWithCompletionHandler(std::function<void()>);
</ins><span class="cx"> };
</span><span class="cx">
</span><span class="cx"> }
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformiosWebVideoFullscreenInterfaceAVKitmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/platform/ios/WebVideoFullscreenInterfaceAVKit.mm        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -273,7 +273,7 @@
</span><span class="cx"> m_playerController.get().playerLayer = (CALayer<AVPlayerLayer>*)videoLayer;
</span><span class="cx"> }
</span><span class="cx">
</span><del>-void WebVideoFullscreenInterfaceAVKit::enterFullscreen(std::function<void()> completion)
</del><ins>+void WebVideoFullscreenInterfaceAVKit::enterFullscreenWithCompletionHandler(std::function<void()> completion)
</ins><span class="cx"> {
</span><span class="cx"> RefPtr<WebVideoFullscreenInterfaceAVKit> strongThis(this);
</span><span class="cx">
</span><span class="lines">@@ -299,10 +299,10 @@
</span><span class="cx">
</span><span class="cx"> void WebVideoFullscreenInterfaceAVKit::enterFullscreen()
</span><span class="cx"> {
</span><del>- enterFullscreen(nullptr);
</del><ins>+ enterFullscreenWithCompletionHandler(nullptr);
</ins><span class="cx"> }
</span><span class="cx">
</span><del>-void WebVideoFullscreenInterfaceAVKit::exitFullscreen(std::function<void()> completion)
</del><ins>+void WebVideoFullscreenInterfaceAVKit::exitFullscreenWithCompletionHandler(std::function<void()> completion)
</ins><span class="cx"> {
</span><span class="cx"> m_playerController.clear();
</span><span class="cx"> RefPtr<WebVideoFullscreenInterfaceAVKit> strongThis(this);
</span><span class="lines">@@ -324,7 +324,7 @@
</span><span class="cx">
</span><span class="cx"> void WebVideoFullscreenInterfaceAVKit::exitFullscreen()
</span><span class="cx"> {
</span><del>- exitFullscreen(nullptr);
</del><ins>+ exitFullscreenWithCompletionHandler(nullptr);
</ins><span class="cx"> }
</span><span class="cx">
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformiosWebVideoFullscreenModelMediaElementh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.h (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.h        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.h        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -47,7 +47,7 @@
</span><span class="cx">
</span><span class="cx"> public:
</span><span class="cx"> WebVideoFullscreenModelMediaElement();
</span><del>- virtual ~WebVideoFullscreenModelMediaElement() { }
</del><ins>+ virtual ~WebVideoFullscreenModelMediaElement();
</ins><span class="cx"> void setWebVideoFullscreenInterface(WebVideoFullscreenInterface* interface) {m_videoFullscreenInterface = interface;}
</span><span class="cx"> void setMediaElement(HTMLMediaElement*);
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebCoreplatformiosWebVideoFullscreenModelMediaElementmm"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.mm (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.mm        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebCore/platform/ios/WebVideoFullscreenModelMediaElement.mm        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -37,6 +37,7 @@
</span><span class="cx"> #import <WebCore/EventListener.h>
</span><span class="cx"> #import <WebCore/EventNames.h>
</span><span class="cx"> #import <WebCore/HTMLElement.h>
</span><ins>+#import <WebCore/HTMLMediaElement.h>
</ins><span class="cx"> #import <WebCore/HTMLVideoElement.h>
</span><span class="cx"> #import <WebCore/SoftLinking.h>
</span><span class="cx"> #import <WebCore/WebCoreThreadRun.h>
</span><span class="lines">@@ -50,6 +51,10 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx">
</span><ins>+WebVideoFullscreenModelMediaElement::~WebVideoFullscreenModelMediaElement()
+{
+}
+
</ins><span class="cx"> void WebVideoFullscreenModelMediaElement::setMediaElement(HTMLMediaElement* mediaElement)
</span><span class="cx"> {
</span><span class="cx"> if (m_mediaElement == mediaElement)
</span></span></pre></div>
<a id="trunkSourceWebKit2ChangeLog"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/ChangeLog (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/ChangeLog        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/ChangeLog        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -1,3 +1,79 @@
</span><ins>+2014-02-06 Jeremy Jones <jeremyj@apple.com>
+
+ Add support for AVKit fullscreen to WebKit2
+ https://bugs.webkit.org/show_bug.cgi?id=128143
+
+ Reviewed by Simon Fraser.
+
+ Add WebVideoFullscreenManager and WebVideoFullscreenManagerProxy that implement
+ WebVideoFullscreenModel and WebVideoFullscreenInterface.
+
+ * DerivedSources.make:
+ * UIProcess/WebPageProxy.cpp:
+ (WebKit::WebPageProxy::WebPageProxy):
+ initialize member m_videoFullscreenManager
+
+ (WebKit::WebPageProxy::videoFullscreenManager):
+ add accessor for videoFullscreenManager
+
+ * UIProcess/WebPageProxy.h:
+ * UIProcess/WebVideoFullscreenManagerProxy.cpp: Added.
+ (WebKit::WebVideoFullscreenManagerProxy::create):
+ (WebKit::WebVideoFullscreenManagerProxy::WebVideoFullscreenManagerProxy):
+ (WebKit::WebVideoFullscreenManagerProxy::~WebVideoFullscreenManagerProxy):
+ add basic creation for object.
+
+ (WebKit::WebVideoFullscreenManagerProxy::setVideoLayerID):
+ (WebKit::WebVideoFullscreenManagerProxy::requestExitFullScreen):
+ (WebKit::WebVideoFullscreenManagerProxy::play):
+ (WebKit::WebVideoFullscreenManagerProxy::pause):
+ (WebKit::WebVideoFullscreenManagerProxy::togglePlayState):
+ (WebKit::WebVideoFullscreenManagerProxy::seekToTime):
+ (WebKit::WebVideoFullscreenManagerProxy::didExitFullscreen):
+ implement WebVideoFullscreenModel to send IPC message.
+
+ * UIProcess/WebVideoFullscreenManagerProxy.h: Added.
+ * UIProcess/WebVideoFullscreenManagerProxy.messages.in: Added.
+ this interface closely matches WebVideoFullscreenInterface
+
+ * WebKit2.xcodeproj/project.pbxproj:
+ * WebProcess/WebCoreSupport/WebChromeClient.cpp:
+ (WebKit::WebChromeClient::supportsFullscreenForNode):
+ (WebKit::WebChromeClient::enterFullscreenForNode):
+ (WebKit::WebChromeClient::exitFullscreenForNode):
+ Forward these requests onto the videoFullscreenManager
+
+ * WebProcess/WebCoreSupport/WebChromeClient.h:
+ * WebProcess/WebPage/WebPage.cpp:
+ (WebKit::WebPage::videoFullscreenManager):
+ accessor for m_videoFullscreenManager
+
+ * WebProcess/WebPage/WebPage.h:
+ * WebProcess/WebVideoFullscreenManager.cpp: Added.
+ (WebKit::WebVideoFullscreenManager::create):
+ (WebKit::WebVideoFullscreenManager::WebVideoFullscreenManager):
+ (WebKit::WebVideoFullscreenManager::~WebVideoFullscreenManager):
+ add basic creation for object.
+
+ (WebKit::WebVideoFullscreenManager::supportsFullscreen):
+ (WebKit::WebVideoFullscreenManager::enterFullscreenForNode):
+ (WebKit::WebVideoFullscreenManager::exitFullscreenForNode):
+ implement interface called by WebChromeClient
+
+ (WebKit::WebVideoFullscreenManager::setDuration):
+ (WebKit::WebVideoFullscreenManager::setCurrentTime):
+ (WebKit::WebVideoFullscreenManager::setRate):
+ (WebKit::WebVideoFullscreenManager::setVideoDimensions):
+ (WebKit::WebVideoFullscreenManager::setVideoLayer):
+ (WebKit::WebVideoFullscreenManager::setVideoLayerID):
+ (WebKit::WebVideoFullscreenManager::enterFullscreen):
+ (WebKit::WebVideoFullscreenManager::exitFullscreen):
+ implement WebVideoFullscreenInterface to send IPC message.
+
+ * WebProcess/WebVideoFullscreenManager.h: Added.
+ * WebProcess/WebVideoFullscreenManager.messages.in: Added.
+ this interface closely matches WebVideoFullscreenModel
+
</ins><span class="cx"> 2014-02-06 Anders Carlsson <andersca@apple.com>
</span><span class="cx">
</span><span class="cx"> Begin work on making preferences per page instead of per page group
</span></span></pre></div>
<a id="trunkSourceWebKit2DerivedSourcesmake"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/DerivedSources.make (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/DerivedSources.make        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/DerivedSources.make        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -50,6 +50,7 @@
</span><span class="cx"> $(WebKit2)/WebProcess/Storage \
</span><span class="cx"> $(WebKit2)/WebProcess/WebCoreSupport \
</span><span class="cx"> $(WebKit2)/WebProcess/WebPage \
</span><ins>+ $(WebKit2)/WebProcess/ios \
</ins><span class="cx"> $(WebKit2)/WebProcess \
</span><span class="cx"> $(WebKit2)/UIProcess \
</span><span class="cx"> $(WebKit2)/UIProcess/Databases \
</span><span class="lines">@@ -60,6 +61,7 @@
</span><span class="cx"> $(WebKit2)/UIProcess/Plugins \
</span><span class="cx"> $(WebKit2)/UIProcess/Storage \
</span><span class="cx"> $(WebKit2)/UIProcess/mac \
</span><ins>+ $(WebKit2)/UIProcess/ios \
</ins><span class="cx"> #
</span><span class="cx">
</span><span class="cx"> MESSAGE_RECEIVERS = \
</span><span class="lines">@@ -126,6 +128,8 @@
</span><span class="cx"> WebResourceCacheManager \
</span><span class="cx"> WebResourceCacheManagerProxy \
</span><span class="cx"> WebResourceLoader \
</span><ins>+ WebVideoFullscreenManager \
+ WebVideoFullscreenManagerProxy \
</ins><span class="cx"> #
</span><span class="cx">
</span><span class="cx"> SCRIPTS = \
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessWebPageProxycpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.cpp        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -96,8 +96,8 @@
</span><span class="cx"> #include <WebCore/RenderEmbeddedObject.h>
</span><span class="cx"> #include <WebCore/TextCheckerClient.h>
</span><span class="cx"> #include <WebCore/WindowFeatures.h>
</span><ins>+#include <stdio.h>
</ins><span class="cx"> #include <wtf/NeverDestroyed.h>
</span><del>-#include <stdio.h>
</del><span class="cx">
</span><span class="cx"> #if ENABLE(ASYNC_SCROLLING)
</span><span class="cx"> #include "RemoteScrollingCoordinatorProxy.h"
</span><span class="lines">@@ -131,6 +131,11 @@
</span><span class="cx"> #include "ViewSnapshotStore.h"
</span><span class="cx"> #endif
</span><span class="cx">
</span><ins>+#if PLATFORM(IOS)
+#include "WebVideoFullscreenManagerProxy.h"
+#include "WebVideoFullscreenManagerProxyMessages.h"
+#endif
+
</ins><span class="cx"> // This controls what strategy we use for mouse wheel coalescing.
</span><span class="cx"> #define MERGE_WHEEL_EVENTS 1
</span><span class="cx">
</span><span class="lines">@@ -349,6 +354,9 @@
</span><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> m_fullScreenManager = WebFullScreenManagerProxy::create(*this, m_pageClient.fullScreenManagerProxyClient());
</span><span class="cx"> #endif
</span><ins>+#if PLATFORM(IOS)
+ m_videoFullscreenManager = WebVideoFullscreenManagerProxy::create(*this);
+#endif
</ins><span class="cx"> #if ENABLE(VIBRATION)
</span><span class="cx"> m_vibration = WebVibrationProxy::create(this);
</span><span class="cx"> #endif
</span><span class="lines">@@ -2971,6 +2979,13 @@
</span><span class="cx"> return m_fullScreenManager.get();
</span><span class="cx"> }
</span><span class="cx"> #endif
</span><ins>+
+#if PLATFORM(IOS)
+RefPtr<WebVideoFullscreenManagerProxy> WebPageProxy::videoFullscreenManager()
+{
+ return m_videoFullscreenManager;
+}
+#endif
</ins><span class="cx">
</span><span class="cx"> // BackForwardList
</span><span class="cx">
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessWebPageProxyh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/UIProcess/WebPageProxy.h (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/WebPageProxy.h        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/UIProcess/WebPageProxy.h        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -149,6 +149,7 @@
</span><span class="cx"> class WebContextMenuProxy;
</span><span class="cx"> class WebEditCommandProxy;
</span><span class="cx"> class WebFullScreenManagerProxy;
</span><ins>+class WebVideoFullscreenManagerProxy;
</ins><span class="cx"> class WebKeyboardEvent;
</span><span class="cx"> class WebMouseEvent;
</span><span class="cx"> class WebOpenPanelResultListenerProxy;
</span><span class="lines">@@ -362,6 +363,9 @@
</span><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> WebFullScreenManagerProxy* fullScreenManager();
</span><span class="cx"> #endif
</span><ins>+#if PLATFORM(IOS)
+ RefPtr<WebVideoFullscreenManagerProxy> videoFullscreenManager();
+#endif
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(CONTEXT_MENUS)
</span><span class="cx"> void initializeContextMenuClient(const WKPageContextMenuClientBase*);
</span><span class="lines">@@ -1215,6 +1219,9 @@
</span><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> RefPtr<WebFullScreenManagerProxy> m_fullScreenManager;
</span><span class="cx"> #endif
</span><ins>+#if PLATFORM(IOS)
+ RefPtr<WebVideoFullscreenManagerProxy> m_videoFullscreenManager;
+#endif
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(VIBRATION)
</span><span class="cx"> RefPtr<WebVibrationProxy> m_vibration;
</span></span></pre></div>
<a id="trunkSourceWebKit2UIProcessiosWebVideoFullscreenManagerProxycpp"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.cpp (0 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.cpp         (rev 0)
+++ trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.cpp        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -0,0 +1,96 @@
</span><ins>+/*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "config.h"
+#include "WebVideoFullscreenManagerProxy.h"
+
+#if PLATFORM(IOS)
+
+#include "WebPageProxy.h"
+#include "WebProcessProxy.h"
+#include "WebVideoFullscreenManagerMessages.h"
+#include "WebVideoFullscreenManagerProxyMessages.h"
+
+using namespace WebCore;
+
+namespace WebKit {
+
+PassRefPtr<WebVideoFullscreenManagerProxy> WebVideoFullscreenManagerProxy::create(WebPageProxy& page)
+{
+ return adoptRef(new WebVideoFullscreenManagerProxy(page));
+}
+
+WebVideoFullscreenManagerProxy::WebVideoFullscreenManagerProxy(WebPageProxy& page)
+ : m_page(&page)
+{
+ m_page->process().addMessageReceiver(Messages::WebVideoFullscreenManagerProxy::messageReceiverName(), m_page->pageID(), *this);
+ setWebVideoFullscreenModel(this);
+}
+
+WebVideoFullscreenManagerProxy::~WebVideoFullscreenManagerProxy()
+{
+ m_page->process().removeMessageReceiver(Messages::WebVideoFullscreenManagerProxy::messageReceiverName(), m_page->pageID());
+}
+
+void WebVideoFullscreenManagerProxy::setVideoLayerID(uint32_t videoLayerID)
+{
+ // TODO: find a real video layer or make one that meets the necessary requirements.
+ setVideoLayer(nullptr);
+}
+
+void WebVideoFullscreenManagerProxy::requestExitFullScreen()
+{
+ m_page->send(Messages::WebVideoFullscreenManager::RequestExitFullScreen(), m_page->pageID());
+}
+
+void WebVideoFullscreenManagerProxy::play()
+{
+ m_page->send(Messages::WebVideoFullscreenManager::Play(), m_page->pageID());
+}
+
+void WebVideoFullscreenManagerProxy::pause()
+{
+ m_page->send(Messages::WebVideoFullscreenManager::Pause(), m_page->pageID());
+}
+
+void WebVideoFullscreenManagerProxy::togglePlayState()
+{
+ m_page->send(Messages::WebVideoFullscreenManager::TogglePlayState(), m_page->pageID());
+}
+
+void WebVideoFullscreenManagerProxy::seekToTime(double time)
+{
+ m_page->send(Messages::WebVideoFullscreenManager::SeekToTime(time), m_page->pageID());
+}
+
+void WebVideoFullscreenManagerProxy::didExitFullscreen()
+{
+ m_page->send(Messages::WebVideoFullscreenManager::DidExitFullscreen(), m_page->pageID());
+}
+
+
+} // namespace WebKit
+
+#endif // PLATFORM(IOS)
</ins></span></pre></div>
<a id="trunkSourceWebKit2UIProcessiosWebVideoFullscreenManagerProxyh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.h (0 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.h         (rev 0)
+++ trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.h        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -0,0 +1,67 @@
</span><ins>+/*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef WebVideoFullscreenManagerProxy_h
+#define WebVideoFullscreenManagerProxy_h
+
+#if PLATFORM(IOS)
+
+#include "MessageReceiver.h"
+#include <WebCore/WebVideoFullscreenInterfaceAVKit.h>
+#include <WebCore/WebVideoFullscreenModel.h>
+#include <wtf/PassRefPtr.h>
+#include <wtf/RefCounted.h>
+#include <wtf/RefPtr.h>
+
+namespace WebKit {
+
+class WebPageProxy;
+
+class WebVideoFullscreenManagerProxy : public WebCore::WebVideoFullscreenInterfaceAVKit, public WebCore::WebVideoFullscreenModel, private IPC::MessageReceiver {
+public:
+ static PassRefPtr<WebVideoFullscreenManagerProxy> create(WebPageProxy&);
+ virtual ~WebVideoFullscreenManagerProxy();
+
+private:
+ explicit WebVideoFullscreenManagerProxy(WebPageProxy&);
+ virtual void didReceiveMessage(IPC::Connection*, IPC::MessageDecoder&) override;
+
+ virtual void setVideoLayerID(uint32_t) override;
+
+ virtual void requestExitFullScreen() override;
+ virtual void play() override;
+ virtual void pause() override;
+ virtual void togglePlayState() override;
+ virtual void seekToTime(double) override;
+ virtual void didExitFullscreen() override;
+
+ WebPageProxy* m_page;
+};
+
+} // namespace WebKit
+
+#endif // PLATFORM(IOS)
+
+#endif // WebVideoFullscreenManagerProxy_h
</ins></span></pre></div>
<a id="trunkSourceWebKit2UIProcessiosWebVideoFullscreenManagerProxymessagesin"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in (0 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in         (rev 0)
+++ trunk/Source/WebKit2/UIProcess/ios/WebVideoFullscreenManagerProxy.messages.in        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -0,0 +1,34 @@
</span><ins>+# Copyright (C) 2014 Apple Inc. All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR
+# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+# changes here must be reflected in WebVideoFullscreenModel
+#if PLATFORM(IOS)
+messages -> WebVideoFullscreenManagerProxy {
+ SetCurrentTime(double currentTime, double hostTime)
+ SetVideoLayerID(uint32_t videoLayerID)
+ SetVideoDimensions(bool hasVideo, unsigned width, unsigned height)
+ SetDuration(double duration)
+ SetRate(bool isPlaying, double rate)
+ EnterFullscreen()
+ ExitFullscreen()
+}
+#endif
</ins></span></pre></div>
<a id="trunkSourceWebKit2WebKit2xcodeprojprojectpbxproj"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/WebKit2.xcodeproj/project.pbxproj        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -606,9 +606,14 @@
</span><span class="cx">                 37FC19471850FBF2008CFA47 /* WKBrowsingContextLoadDelegatePrivate.h in Headers */ = {isa = PBXBuildFile; fileRef = 37FC19461850FBF2008CFA47 /* WKBrowsingContextLoadDelegatePrivate.h */; settings = {ATTRIBUTES = (Private, ); }; };
</span><span class="cx">                 37FC194A18510D6A008CFA47 /* WKNSURLAuthenticationChallenge.mm in Sources */ = {isa = PBXBuildFile; fileRef = 37FC194818510D6A008CFA47 /* WKNSURLAuthenticationChallenge.mm */; };
</span><span class="cx">                 37FC194B18510D6A008CFA47 /* WKNSURLAuthenticationChallenge.h in Headers */ = {isa = PBXBuildFile; fileRef = 37FC194918510D6A008CFA47 /* WKNSURLAuthenticationChallenge.h */; };
</span><ins>+                3F418EF91887BD97002795FD /* WebVideoFullscreenManagerMessageReceiver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3F418EF51887BD97002795FD /* WebVideoFullscreenManagerMessageReceiver.cpp */; };
+                3F418EFB1887BD97002795FD /* WebVideoFullscreenManagerProxyMessageReceiver.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3F418EF71887BD97002795FD /* WebVideoFullscreenManagerProxyMessageReceiver.cpp */; };
</ins><span class="cx">                 3F87B9BD158940120090FF62 /* WebColorChooser.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3F87B9BA15893F630090FF62 /* WebColorChooser.cpp */; };
</span><span class="cx">                 3F87B9BE158940190090FF62 /* WebColorChooser.h in Headers */ = {isa = PBXBuildFile; fileRef = 3F87B9BB15893F630090FF62 /* WebColorChooser.h */; };
</span><span class="cx">                 3F87B9C0158940D80090FF62 /* WebColorPicker.h in Headers */ = {isa = PBXBuildFile; fileRef = 3F87B9BF158940D80090FF62 /* WebColorPicker.h */; };
</span><ins>+                3F889D14188778C900FEADAF /* WebVideoFullscreenManagerProxy.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3F889D12188778C900FEADAF /* WebVideoFullscreenManagerProxy.cpp */; };
+                3F889D15188778C900FEADAF /* WebVideoFullscreenManagerProxy.h in Headers */ = {isa = PBXBuildFile; fileRef = 3F889D13188778C900FEADAF /* WebVideoFullscreenManagerProxy.h */; };
+                3F889D171887859300FEADAF /* WebVideoFullscreenManager.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 3F889D0D1887699C00FEADAF /* WebVideoFullscreenManager.cpp */; };
</ins><span class="cx">                 4F601432155C5AA2001FBDE0 /* BlockingResponseMap.h in Headers */ = {isa = PBXBuildFile; fileRef = 4F601430155C5A32001FBDE0 /* BlockingResponseMap.h */; };
</span><span class="cx">                 51021E9C12B16788005C033C /* WebContextMenuClientMac.mm in Sources */ = {isa = PBXBuildFile; fileRef = 51021E9B12B16788005C033C /* WebContextMenuClientMac.mm */; };
</span><span class="cx">                 51032F18180F73BB00961BB7 /* WebToDatabaseProcessConnection.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 51032F16180F73BB00961BB7 /* WebToDatabaseProcessConnection.cpp */; };
</span><span class="lines">@@ -2300,9 +2305,19 @@
</span><span class="cx">                 37FC19461850FBF2008CFA47 /* WKBrowsingContextLoadDelegatePrivate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKBrowsingContextLoadDelegatePrivate.h; sourceTree = "<group>"; };
</span><span class="cx">                 37FC194818510D6A008CFA47 /* WKNSURLAuthenticationChallenge.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WKNSURLAuthenticationChallenge.mm; sourceTree = "<group>"; };
</span><span class="cx">                 37FC194918510D6A008CFA47 /* WKNSURLAuthenticationChallenge.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WKNSURLAuthenticationChallenge.h; sourceTree = "<group>"; };
</span><ins>+                3F418EF51887BD97002795FD /* WebVideoFullscreenManagerMessageReceiver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebVideoFullscreenManagerMessageReceiver.cpp; sourceTree = "<group>"; };
+                3F418EF61887BD97002795FD /* WebVideoFullscreenManagerMessages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebVideoFullscreenManagerMessages.h; sourceTree = "<group>"; };
+                3F418EF71887BD97002795FD /* WebVideoFullscreenManagerProxyMessageReceiver.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebVideoFullscreenManagerProxyMessageReceiver.cpp; sourceTree = "<group>"; };
+                3F418EF81887BD97002795FD /* WebVideoFullscreenManagerProxyMessages.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebVideoFullscreenManagerProxyMessages.h; sourceTree = "<group>"; };
</ins><span class="cx">                 3F87B9BA15893F630090FF62 /* WebColorChooser.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = WebColorChooser.cpp; sourceTree = "<group>"; };
</span><span class="cx">                 3F87B9BB15893F630090FF62 /* WebColorChooser.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebColorChooser.h; sourceTree = "<group>"; };
</span><span class="cx">                 3F87B9BF158940D80090FF62 /* WebColorPicker.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WebColorPicker.h; sourceTree = "<group>"; };
</span><ins>+                3F889D0D1887699C00FEADAF /* WebVideoFullscreenManager.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = WebVideoFullscreenManager.cpp; path = ios/WebVideoFullscreenManager.cpp; sourceTree = "<group>"; };
+                3F889D0E1887699C00FEADAF /* WebVideoFullscreenManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WebVideoFullscreenManager.h; path = ios/WebVideoFullscreenManager.h; sourceTree = "<group>"; };
+                3F889D101887710000FEADAF /* WebVideoFullscreenManager.messages.in */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; name = WebVideoFullscreenManager.messages.in; path = ios/WebVideoFullscreenManager.messages.in; sourceTree = "<group>"; };
+                3F889D12188778C900FEADAF /* WebVideoFullscreenManagerProxy.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = WebVideoFullscreenManagerProxy.cpp; path = ios/WebVideoFullscreenManagerProxy.cpp; sourceTree = "<group>"; };
+                3F889D13188778C900FEADAF /* WebVideoFullscreenManagerProxy.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = WebVideoFullscreenManagerProxy.h; path = ios/WebVideoFullscreenManagerProxy.h; sourceTree = "<group>"; };
+                3F889D1618877A2400FEADAF /* WebVideoFullscreenManagerProxy.messages.in */ = {isa = PBXFileReference; lastKnownFileType = text; name = WebVideoFullscreenManagerProxy.messages.in; path = ios/WebVideoFullscreenManagerProxy.messages.in; sourceTree = "<group>"; };
</ins><span class="cx">                 4F601430155C5A32001FBDE0 /* BlockingResponseMap.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BlockingResponseMap.h; sourceTree = "<group>"; };
</span><span class="cx">                 510031F61379CACB00C8DFE4 /* SecItemShim.dylib */ = {isa = PBXFileReference; explicitFileType = "compiled.mach-o.dylib"; includeInIndex = 0; path = SecItemShim.dylib; sourceTree = BUILT_PRODUCTS_DIR; };
</span><span class="cx">                 51021E9B12B16788005C033C /* WebContextMenuClientMac.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; path = WebContextMenuClientMac.mm; sourceTree = "<group>"; };
</span><span class="lines">@@ -4198,6 +4213,9 @@
</span><span class="cx">                                 2DA944AA1884E9BA00ED86DB /* WebInspectorProxyIOS.mm */,
</span><span class="cx">                                 2DA944AB1884E9BA00ED86DB /* WebPageProxyIOS.mm */,
</span><span class="cx">                                 2DA944AC1884E9BA00ED86DB /* WebProcessProxyIOS.mm */,
</span><ins>+                                3F889D12188778C900FEADAF /* WebVideoFullscreenManagerProxy.cpp */,
+                                3F889D13188778C900FEADAF /* WebVideoFullscreenManagerProxy.h */,
+                                3F889D1618877A2400FEADAF /* WebVideoFullscreenManagerProxy.messages.in */,
</ins><span class="cx">                         );
</span><span class="cx">                         name = ios;
</span><span class="cx">                         sourceTree = "<group>";
</span><span class="lines">@@ -4206,6 +4224,9 @@
</span><span class="cx">                         isa = PBXGroup;
</span><span class="cx">                         children = (
</span><span class="cx">                                 2DA944B21884E9EC00ED86DB /* WebProcessIOS.mm */,
</span><ins>+                                3F889D0D1887699C00FEADAF /* WebVideoFullscreenManager.cpp */,
+                                3F889D0E1887699C00FEADAF /* WebVideoFullscreenManager.h */,
+                                3F889D101887710000FEADAF /* WebVideoFullscreenManager.messages.in */,
</ins><span class="cx">                         );
</span><span class="cx">                         name = ios;
</span><span class="cx">                         sourceTree = "<group>";
</span><span class="lines">@@ -6042,6 +6063,10 @@
</span><span class="cx">                                 33367654130C9ECA006C9DE2 /* WebResourceCacheManagerProxyMessages.h */,
</span><span class="cx">                                 51F060DD1654317500F3281B /* WebResourceLoaderMessageReceiver.cpp */,
</span><span class="cx">                                 51F060DE1654317500F3281B /* WebResourceLoaderMessages.h */,
</span><ins>+                                3F418EF51887BD97002795FD /* WebVideoFullscreenManagerMessageReceiver.cpp */,
+                                3F418EF61887BD97002795FD /* WebVideoFullscreenManagerMessages.h */,
+                                3F418EF71887BD97002795FD /* WebVideoFullscreenManagerProxyMessageReceiver.cpp */,
+                                3F418EF81887BD97002795FD /* WebVideoFullscreenManagerProxyMessages.h */,
</ins><span class="cx">                         );
</span><span class="cx">                         name = "Derived Sources";
</span><span class="cx">                         path = DerivedSources/WebKit2;
</span><span class="lines">@@ -6603,6 +6628,7 @@
</span><span class="cx">                                 BC1DFEA412B31F87005DF730 /* WebOpenPanelResultListenerProxy.h in Headers */,
</span><span class="cx">                                 BC032D8F10F437A00058C15A /* WebPage.h in Headers */,
</span><span class="cx">                                 5153569D1291B1D2000749DC /* WebPageContextMenuClient.h in Headers */,
</span><ins>+                                3F889D15188778C900FEADAF /* WebVideoFullscreenManagerProxy.h in Headers */,
</ins><span class="cx">                                 BC7B6206129A0A6700D174A4 /* WebPageGroup.h in Headers */,
</span><span class="cx">                                 BC7B625212A43C9600D174A4 /* WebPageGroupData.h in Headers */,
</span><span class="cx">                                 BC7B621512A4219A00D174A4 /* WebPageGroupProxy.h in Headers */,
</span><span class="lines">@@ -7921,6 +7947,7 @@
</span><span class="cx">                                 F6A25FDC12ADC6CC00DC40CC /* WebDatabaseManager.cpp in Sources */,
</span><span class="cx">                                 F62A76B612B1B25F0005F1B6 /* WebDatabaseManagerMessageReceiver.cpp in Sources */,
</span><span class="cx">                                 51E35209180F5D6B00E53BE9 /* DatabaseServiceEntryPoint.mm in Sources */,
</span><ins>+                                3F418EF91887BD97002795FD /* WebVideoFullscreenManagerMessageReceiver.cpp in Sources */,
</ins><span class="cx">                                 F62A765C12B1ABC30005F1B6 /* WebDatabaseManagerProxy.cpp in Sources */,
</span><span class="cx">                                 BCAC112012C92C1F00B08EEE /* WebDatabaseManagerProxyClient.cpp in Sources */,
</span><span class="cx">                                 F62A76B812B1B25F0005F1B6 /* WebDatabaseManagerProxyMessageReceiver.cpp in Sources */,
</span><span class="lines">@@ -8056,6 +8083,7 @@
</span><span class="cx">                                 33367635130C99B2006C9DE2 /* WebResourceCacheManagerProxy.cpp in Sources */,
</span><span class="cx">                                 33367657130C9ECA006C9DE2 /* WebResourceCacheManagerProxyMessageReceiver.cpp in Sources */,
</span><span class="cx">                                 510AFFB916542048001BA05E /* WebResourceLoader.cpp in Sources */,
</span><ins>+                                3F889D14188778C900FEADAF /* WebVideoFullscreenManagerProxy.cpp in Sources */,
</ins><span class="cx">                                 51F060E11654318500F3281B /* WebResourceLoaderMessageReceiver.cpp in Sources */,
</span><span class="cx">                                 378E1A3D181ED6FF0031007A /* APIObject.mm in Sources */,
</span><span class="cx">                                 51FB08FF1639DE1A00EC324A /* WebResourceLoadScheduler.cpp in Sources */,
</span><span class="lines">@@ -8166,7 +8194,9 @@
</span><span class="cx">                                 BC85806312B8505700EDEB2E /* WKOpenPanelParameters.cpp in Sources */,
</span><span class="cx">                                 BC85806212B8505700EDEB2E /* WKOpenPanelResultListener.cpp in Sources */,
</span><span class="cx">                                 51FCB18817BBFE0300394CD8 /* SynchronousNetworkLoaderClient.cpp in Sources */,
</span><ins>+                                3F418EFB1887BD97002795FD /* WebVideoFullscreenManagerProxyMessageReceiver.cpp in Sources */,
</ins><span class="cx">                                 BCD597D6112B56DC00EC8C23 /* WKPage.cpp in Sources */,
</span><ins>+                                3F889D171887859300FEADAF /* WebVideoFullscreenManager.cpp in Sources */,
</ins><span class="cx">                                 BC7B633812A45ABA00D174A4 /* WKPageGroup.cpp in Sources */,
</span><span class="cx">                                 BCE17B7D1381F1170012A641 /* WKPagePrivateMac.cpp in Sources */,
</span><span class="cx">                                 7C135AA8173B0BCA00586AE2 /* WKPluginInformation.cpp in Sources */,
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebChromeClientcpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.cpp        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -69,6 +69,10 @@
</span><span class="cx"> #include <WebCore/SecurityOrigin.h>
</span><span class="cx"> #include <WebCore/Settings.h>
</span><span class="cx">
</span><ins>+#if PLATFORM(IOS)
+#include "WebVideoFullscreenManager.h"
+#endif
+
</ins><span class="cx"> #if ENABLE(ASYNC_SCROLLING)
</span><span class="cx"> #include "RemoteScrollingCoordinator.h"
</span><span class="cx"> #endif
</span><span class="lines">@@ -821,6 +825,23 @@
</span><span class="cx"> }
</span><span class="cx"> #endif
</span><span class="cx">
</span><ins>+#if PLATFORM(IOS)
+bool WebChromeClient::supportsFullscreenForNode(const WebCore::Node* node)
+{
+ return m_page->videoFullscreenManager()->supportsFullscreen(node);
+}
+
+void WebChromeClient::enterFullscreenForNode(WebCore::Node* node)
+{
+ m_page->videoFullscreenManager()->enterFullscreenForNode(node);
+}
+
+void WebChromeClient::exitFullscreenForNode(WebCore::Node* node)
+{
+ m_page->videoFullscreenManager()->exitFullscreenForNode(node);
+}
+#endif
+
</ins><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> bool WebChromeClient::supportsFullScreenForElement(const WebCore::Element*, bool withKeyboard)
</span><span class="cx"> {
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebCoreSupportWebChromeClienth"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/WebProcess/WebCoreSupport/WebChromeClient.h        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -238,6 +238,12 @@
</span><span class="cx"> virtual void elementDidBlur(const WebCore::Node*) override;
</span><span class="cx"> #endif
</span><span class="cx">
</span><ins>+#if PLATFORM(IOS)
+ virtual bool supportsFullscreenForNode(const WebCore::Node*);
+ virtual void enterFullscreenForNode(WebCore::Node*);
+ virtual void exitFullscreenForNode(WebCore::Node*);
+#endif
+
</ins><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> virtual bool supportsFullScreenForElement(const WebCore::Element*, bool withKeyboard) override;
</span><span class="cx"> virtual void enterFullScreenForElement(WebCore::Element*) override;
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageWebPagecpp"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.cpp        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -182,6 +182,10 @@
</span><span class="cx"> #include "WebPrintOperationGtk.h"
</span><span class="cx"> #endif
</span><span class="cx">
</span><ins>+#if PLATFORM(IOS)
+#include "WebVideoFullscreenManager.h"
+#endif
+
</ins><span class="cx"> #ifndef NDEBUG
</span><span class="cx"> #include <wtf/RefCountedLeakCounter.h>
</span><span class="cx"> #endif
</span><span class="lines">@@ -2584,6 +2588,15 @@
</span><span class="cx"> return m_inspector.get();
</span><span class="cx"> }
</span><span class="cx"> #endif
</span><ins>+
+#if PLATFORM(IOS)
+WebVideoFullscreenManager* WebPage::videoFullscreenManager()
+{
+ if (!m_videoFullscreenManager)
+ m_videoFullscreenManager = WebVideoFullscreenManager::create(this);
+ return m_videoFullscreenManager.get();
+}
+#endif
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> WebFullScreenManager* WebPage::fullScreenManager()
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessWebPageWebPageh"></a>
<div class="modfile"><h4>Modified: trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h (163599 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h        2014-02-07 02:18:32 UTC (rev 163599)
+++ trunk/Source/WebKit2/WebProcess/WebPage/WebPage.h        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -154,6 +154,7 @@
</span><span class="cx"> class WebOpenPanelResultListener;
</span><span class="cx"> class WebPageGroupProxy;
</span><span class="cx"> class WebPopupMenu;
</span><ins>+class WebVideoFullscreenManager;
</ins><span class="cx"> class WebWheelEvent;
</span><span class="cx"> struct AttributedString;
</span><span class="cx"> struct EditorState;
</span><span class="lines">@@ -205,6 +206,10 @@
</span><span class="cx"> #if ENABLE(INSPECTOR)
</span><span class="cx"> WebInspector* inspector();
</span><span class="cx"> #endif
</span><ins>+
+#if PLATFORM(IOS)
+ WebVideoFullscreenManager* videoFullscreenManager();
+#endif
</ins><span class="cx">
</span><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> WebFullScreenManager* fullScreenManager();
</span><span class="lines">@@ -1005,6 +1010,9 @@
</span><span class="cx"> #if ENABLE(INSPECTOR)
</span><span class="cx"> RefPtr<WebInspector> m_inspector;
</span><span class="cx"> #endif
</span><ins>+#if PLATFORM(IOS)
+ RefPtr<WebVideoFullscreenManager> m_videoFullscreenManager;
+#endif
</ins><span class="cx"> #if ENABLE(FULLSCREEN_API)
</span><span class="cx"> RefPtr<WebFullScreenManager> m_fullScreenManager;
</span><span class="cx"> #endif
</span></span></pre></div>
<a id="trunkSourceWebKit2WebProcessiosWebVideoFullscreenManagercpp"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.cpp (0 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.cpp         (rev 0)
+++ trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.cpp        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -0,0 +1,124 @@
</span><ins>+/*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+#include "config.h"
+#include "WebVideoFullscreenManager.h"
+
+#if PLATFORM(IOS)
+
+#include "WebPage.h"
+#include "WebProcess.h"
+#include "WebVideoFullscreenManagerMessages.h"
+#include "WebVideoFullscreenManagerProxyMessages.h"
+#include <WebCore/Event.h>
+#include <WebCore/EventNames.h>
+#include <WebCore/HTMLVideoElement.h>
+#include <WebCore/Settings.h>
+
+using namespace WebCore;
+
+namespace WebKit {
+
+PassRefPtr<WebVideoFullscreenManager> WebVideoFullscreenManager::create(PassRefPtr<WebPage> page)
+{
+ return adoptRef(new WebVideoFullscreenManager(page));
+}
+
+WebVideoFullscreenManager::WebVideoFullscreenManager(PassRefPtr<WebPage> page)
+ : m_page(page.get())
+{
+ setWebVideoFullscreenInterface(this);
+ WebProcess::shared().addMessageReceiver(Messages::WebVideoFullscreenManager::messageReceiverName(), page->pageID(), *this);
+}
+
+WebVideoFullscreenManager::~WebVideoFullscreenManager()
+{
+ WebProcess::shared().removeMessageReceiver(Messages::WebVideoFullscreenManager::messageReceiverName(), m_page->pageID());
+}
+
+bool WebVideoFullscreenManager::supportsFullscreen(const Node* node) const
+{
+ if (!Settings::avKitEnabled())
+ return false;
+ return isHTMLVideoElement(node);
+}
+
+void WebVideoFullscreenManager::enterFullscreenForNode(Node* node)
+{
+ ASSERT(node);
+ m_node = node;
+ setMediaElement(toHTMLMediaElement(node));
+ enterFullscreen();
+}
+
+void WebVideoFullscreenManager::exitFullscreenForNode(Node*)
+{
+ exitFullscreen();
+ setMediaElement(nullptr);
+}
+
+void WebVideoFullscreenManager::setDuration(double duration)
+{
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::SetDuration(duration), m_page->pageID());
+}
+
+void WebVideoFullscreenManager::setCurrentTime(double currentTime, double anchorTime)
+{
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::SetCurrentTime(currentTime, anchorTime), m_page->pageID());
+}
+
+void WebVideoFullscreenManager::setRate(bool isPlaying, float playbackRate)
+{
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::SetRate(isPlaying, playbackRate), m_page->pageID());
+}
+
+void WebVideoFullscreenManager::setVideoDimensions(bool hasVideo, float width, float height)
+{
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::SetVideoDimensions(hasVideo, width, height), m_page->pageID());
+}
+
+void WebVideoFullscreenManager::setVideoLayer(PlatformLayer*)
+{
+ // TODO: implement with correct layer ID.
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::SetVideoLayerID(0), m_page->pageID());
+}
+
+void WebVideoFullscreenManager::setVideoLayerID(uint32_t videoLayerID)
+{
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::SetVideoLayerID(videoLayerID), m_page->pageID());
+}
+
+void WebVideoFullscreenManager::enterFullscreen()
+{
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::EnterFullscreen(), m_page->pageID());
+}
+
+void WebVideoFullscreenManager::exitFullscreen()
+{
+ m_page->send(Messages::WebVideoFullscreenManagerProxy::ExitFullscreen(), m_page->pageID());
+}
+
+} // namespace WebKit
+
+#endif // PLATFORM(IOS)
</ins></span></pre></div>
<a id="trunkSourceWebKit2WebProcessiosWebVideoFullscreenManagerh"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.h (0 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.h         (rev 0)
+++ trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.h        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -0,0 +1,83 @@
</span><ins>+/*
+ * Copyright (C) 2014 Apple Inc. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS''
+ * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
+ * THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS
+ * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
+ * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+ * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
+ * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+ * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
+ * THE POSSIBILITY OF SUCH DAMAGE.
+ */
+#ifndef WebVideoFullscreenManager_h
+#define WebVideoFullscreenManager_h
+
+#if PLATFORM(IOS)
+
+#include "MessageReceiver.h"
+#include <WebCore/EventListener.h>
+#include <WebCore/WebVideoFullscreenInterface.h>
+#include <WebCore/WebVideoFullscreenModelMediaElement.h>
+#include <wtf/RefCounted.h>
+#include <wtf/RefPtr.h>
+
+namespace IPC {
+class Connection;
+class MessageDecoder;
+class MessageReceiver;
+}
+
+namespace WebCore {
+class Node;
+}
+
+namespace WebKit {
+
+class WebPage;
+
+class WebVideoFullscreenManager : public WebCore::WebVideoFullscreenModelMediaElement, public WebCore::WebVideoFullscreenInterface, private IPC::MessageReceiver {
+public:
+ static PassRefPtr<WebVideoFullscreenManager> create(PassRefPtr<WebPage>);
+ virtual ~WebVideoFullscreenManager();
+
+ void didReceiveMessage(IPC::Connection*, IPC::MessageDecoder&);
+
+ bool supportsFullscreen(const WebCore::Node*) const;
+ void enterFullscreenForNode(WebCore::Node*);
+ void exitFullscreenForNode(WebCore::Node*);
+
+protected:
+ explicit WebVideoFullscreenManager(PassRefPtr<WebPage>);
+ virtual bool operator==(const EventListener& rhs) override { return static_cast<WebCore::EventListener*>(this) == &rhs; }
+
+ virtual void setDuration(double) override;
+ virtual void setCurrentTime(double currentTime, double anchorTime) override;
+ virtual void setRate(bool isPlaying, float playbackRate) override;
+ virtual void setVideoDimensions(bool hasVideo, float width, float height) override;
+ virtual void setVideoLayer(PlatformLayer*) override;
+ virtual void setVideoLayerID(uint32_t) override;
+ virtual void enterFullscreen() override;
+ virtual void exitFullscreen() override;
+
+ WebPage* m_page;
+ RefPtr<WebCore::Node> m_node;
+};
+
+} // namespace WebKit
+
+#endif // PLATFORM(IOS)
+
+#endif // WebVideoFullscreenManager_h
</ins></span></pre></div>
<a id="trunkSourceWebKit2WebProcessiosWebVideoFullscreenManagermessagesin"></a>
<div class="addfile"><h4>Added: trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.messages.in (0 => 163600)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.messages.in         (rev 0)
+++ trunk/Source/WebKit2/WebProcess/ios/WebVideoFullscreenManager.messages.in        2014-02-07 02:19:55 UTC (rev 163600)
</span><span class="lines">@@ -0,0 +1,33 @@
</span><ins>+# Copyright (C) 2014 Apple Inc. All rights reserved.
+#
+# Redistribution and use in source and binary forms, with or without
+# modification, are permitted provided that the following conditions
+# are met:
+# 1. Redistributions of source code must retain the above copyright
+# notice, this list of conditions and the following disclaimer.
+# 2. Redistributions in binary form must reproduce the above copyright
+# notice, this list of conditions and the following disclaimer in the
+# documentation and/or other materials provided with the distribution.
+#
+# THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND
+# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+# DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR
+# ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
+# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
+# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+# changes here must be reflected in WebVideoFullscreenModel
+#if PLATFORM(IOS)
+messages -> WebVideoFullscreenManager {
+ RequestExitFullScreen()
+ Play()
+ Pause()
+ TogglePlayState()
+ SeekToTime(double time)
+ DidExitFullscreen()
+}
+#endif
</ins></span></pre>
</div>
</div>
</body>
</html>