Title: [199687] trunk/Source/WebCore
- Revision
- 199687
- Author
- [email protected]
- Date
- 2016-04-18 13:50:07 -0700 (Mon, 18 Apr 2016)
Log Message
[iOS] don't toggle playback when media engine rate changes
https://bugs.webkit.org/show_bug.cgi?id=156705
<rdar://problem/25779175>
Reviewed by Jer Noble.
* platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
(WebCore::MediaPlayerPrivateAVFoundation::rateChanged): Don't send the play/pause command
unless the player item state is >= MediaPlayerAVPlayerItemStatusPlaybackBufferFull and
the rate change is unexpected.
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (199686 => 199687)
--- trunk/Source/WebCore/ChangeLog 2016-04-18 20:33:47 UTC (rev 199686)
+++ trunk/Source/WebCore/ChangeLog 2016-04-18 20:50:07 UTC (rev 199687)
@@ -1,3 +1,16 @@
+2016-04-18 Eric Carlson <[email protected]>
+
+ [iOS] don't toggle playback when media engine rate changes
+ https://bugs.webkit.org/show_bug.cgi?id=156705
+ <rdar://problem/25779175>
+
+ Reviewed by Jer Noble.
+
+ * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
+ (WebCore::MediaPlayerPrivateAVFoundation::rateChanged): Don't send the play/pause command
+ unless the player item state is >= MediaPlayerAVPlayerItemStatusPlaybackBufferFull and
+ the rate change is unexpected.
+
2016-04-18 Chris Dumez <[email protected]>
Unreviewed, fix iOS9 build after r199682.
Modified: trunk/Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp (199686 => 199687)
--- trunk/Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp 2016-04-18 20:33:47 UTC (rev 199686)
+++ trunk/Source/WebCore/platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp 2016-04-18 20:50:07 UTC (rev 199687)
@@ -617,8 +617,14 @@
void MediaPlayerPrivateAVFoundation::rateChanged()
{
#if ENABLE(WIRELESS_PLAYBACK_TARGET) && PLATFORM(IOS)
- if (isCurrentPlaybackTargetWireless())
- m_player->handlePlaybackCommand(rate() ? PlatformMediaSession::PlayCommand : PlatformMediaSession::PauseCommand);
+ LOG(Media, "MediaPlayerPrivateAVFoundation::rateChanged(%p) - rate = %f, requested rate = %f, item status = %i", this, rate(), requestedRate(), playerItemStatus());
+ if (isCurrentPlaybackTargetWireless() && playerItemStatus() >= MediaPlayerAVPlayerItemStatusPlaybackBufferFull) {
+ double rate = this->rate();
+ if (rate != requestedRate()) {
+ m_player->handlePlaybackCommand(rate ? PlatformMediaSession::PlayCommand : PlatformMediaSession::PauseCommand);
+ return;
+ }
+ }
#endif
m_player->rateChanged();
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes