Changeset 162870 in webkit


Ignore:
Timestamp:
Jan 27, 2014, 2:47:27 PM (11 years ago)
Author:
eric.carlson@apple.com
Message:

[iOS] preload=none prevents play()
https://bugs.webkit.org/show_bug.cgi?id=127702

Reviewed by Jer Noble.

No new tests, covered by existing tests.

  • html/HTMLMediaElement.cpp:

(WebCore::HTMLMediaElement::potentiallyPlaying): Cleanup logic to make it simpler to understand,

fix logic error introduced in r161973

(WebCore::HTMLMediaElement::updatePlayState): Conditionalize some iOS-only code on whether or not

we are using the plug-in proxy.

Location:
trunk/Source/WebCore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r162869 r162870  
     12014-01-27  Eric Carlson  <eric.carlson@apple.com>
     2
     3        [iOS] preload=none prevents play()
     4        https://bugs.webkit.org/show_bug.cgi?id=127702
     5
     6        Reviewed by Jer Noble.
     7
     8        No new tests, covered by existing tests.
     9
     10        * html/HTMLMediaElement.cpp:
     11        (WebCore::HTMLMediaElement::potentiallyPlaying): Cleanup logic to make it simpler to understand,
     12            fix logic error introduced in r161973
     13        (WebCore::HTMLMediaElement::updatePlayState): Conditionalize some iOS-only code on whether or not
     14            we are using the plug-in proxy.
     15
    1162014-01-27  Brady Eidson  <beidson@apple.com>
    217
  • trunk/Source/WebCore/html/HTMLMediaElement.cpp

    r162503 r162870  
    41094109bool HTMLMediaElement::potentiallyPlaying() const
    41104110{
    4111     // When media engine ran out of buffered data it's not playing.
    4112     if (m_readyStateMaximum < HAVE_FUTURE_DATA && m_readyState < HAVE_FUTURE_DATA)
     4111    if (isBlockedOnMediaController())
    41134112        return false;
    4114 
    4115     return couldPlayIfEnoughData() && !isBlockedOnMediaController();
     4113   
     4114    if (!couldPlayIfEnoughData())
     4115        return false;
     4116
     4117    if (m_readyState >= HAVE_FUTURE_DATA)
     4118        return true;
     4119
     4120    return m_readyStateMaximum >= HAVE_FUTURE_DATA && m_readyState < HAVE_FUTURE_DATA;
    41164121}
    41174122
     
    42434248    bool playerPaused = m_player->paused();
    42444249
    4245 #if PLATFORM(IOS)
    4246     if (shouldBePlaying && !m_requestingPlay && !m_player->readyForPlayback())
    4247         shouldBePlaying = false;
    4248     else if (!shouldBePlaying && m_requestingPlay && m_player->readyForPlayback())
    4249         shouldBePlaying = true;
     4250#if ENABLE(PLUGIN_PROXY_FOR_VIDEO)
     4251    if (shouldUseVideoPluginProxy()) {
     4252        if (shouldBePlaying && !m_requestingPlay && !m_player->readyForPlayback())
     4253            shouldBePlaying = false;
     4254        else if (!shouldBePlaying && m_requestingPlay && m_player->readyForPlayback())
     4255            shouldBePlaying = true;
     4256    }
    42504257#endif
    42514258
  • trunk/Source/WebCore/platform/audio/ios/MediaSessionManagerIOS.mm

    r162360 r162870  
    7474    , m_objcObserver(adoptNS([[WebMediaSessionHelper alloc] initWithCallback:this]))
    7575{
     76    resetRestrictions();
    7677}
    7778
Note: See TracChangeset for help on using the changeset viewer.