Fullscreen controls inoperative in WebKitLegacy web views
authorjer.noble@apple.com <jer.noble@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 22 Sep 2016 20:54:56 +0000 (20:54 +0000)
committerjer.noble@apple.com <jer.noble@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 22 Sep 2016 20:54:56 +0000 (20:54 +0000)
https://bugs.webkit.org/show_bug.cgi?id=162374

Reviewed by Eric Carlson.

After r205365, the WebPlaybackSessionInterfaceAVKit was now created after the
WebPlaybackSessionModel which fed it data, so it no longer received the burst of data upon
creation. Instead, it should have always asked the model for its cached data as soon as it
was connected to set up its inital state.

* platform/ios/WebPlaybackSessionInterfaceAVKit.mm:
(WebCore::WebPlaybackSessionInterfaceAVKit::WebPlaybackSessionInterfaceAVKit):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@206272 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/ios/WebPlaybackSessionInterfaceAVKit.mm

index 4a3da47..80ce42a 100644 (file)
@@ -1,3 +1,18 @@
+2016-09-22  Jer Noble  <jer.noble@apple.com>
+
+        Fullscreen controls inoperative in WebKitLegacy web views
+        https://bugs.webkit.org/show_bug.cgi?id=162374
+
+        Reviewed by Eric Carlson.
+
+        After r205365, the WebPlaybackSessionInterfaceAVKit was now created after the
+        WebPlaybackSessionModel which fed it data, so it no longer received the burst of data upon
+        creation. Instead, it should have always asked the model for its cached data as soon as it
+        was connected to set up its inital state.
+
+        * platform/ios/WebPlaybackSessionInterfaceAVKit.mm:
+        (WebCore::WebPlaybackSessionInterfaceAVKit::WebPlaybackSessionInterfaceAVKit):
+
 2016-09-22  Chris Dumez  <cdumez@apple.com>
 
         Fix serialization of HTML void elements when they have children
index 3c9782d..c18056b 100644 (file)
@@ -54,6 +54,17 @@ WebPlaybackSessionInterfaceAVKit::WebPlaybackSessionInterfaceAVKit(WebPlaybackSe
     model.addClient(*this);
     [m_playerController setPlaybackSessionInterface:this];
     [m_playerController setDelegate:&model];
+
+    durationChanged(model.duration());
+    currentTimeChanged(model.currentTime(), [[NSProcessInfo processInfo] systemUptime]);
+    bufferedTimeChanged(model.bufferedTime());
+    rateChanged(model.isPlaying(), model.playbackRate());
+    seekableRangesChanged(model.seekableRanges());
+    canPlayFastReverseChanged(model.canPlayFastReverse());
+    audioMediaSelectionOptionsChanged(model.audioMediaSelectionOptions(), model.audioMediaSelectedIndex());
+    legibleMediaSelectionOptionsChanged(model.legibleMediaSelectionOptions(), model.legibleMediaSelectedIndex());
+    externalPlaybackChanged(model.externalPlaybackEnabled(), model.externalPlaybackTargetType(), model.externalPlaybackLocalizedDeviceName());
+    wirelessVideoPlaybackDisabledChanged(model.wirelessVideoPlaybackDisabled());
 }
 
 WebPlaybackSessionInterfaceAVKit::~WebPlaybackSessionInterfaceAVKit()