-
eric.carlson@apple.com authored
https://bugs.webkit.org/show_bug.cgi?id=105081 Reviewed by Sam Weinig. Source/WebCore: No new tests, media/track/track-in-band.html was updated to test this change. * html/HTMLMediaElement.cpp: (WebCore::HTMLMediaElement::mediaPlayerDidRemoveTrack): Move some code into removeTrack. (WebCore::HTMLMediaElement::removeTrack): New, remove a track and all of its cues. (WebCore::HTMLMediaElement::removeAllInbandTracks): New, remove all in-band tracks. (WebCore::HTMLMediaElement::clearMediaPlayer): Call removeAllInbandTracks. * html/HTMLMediaElement.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.h: * platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm: (WebCore::MediaPlayerPrivateAVFoundationObjC::~MediaPlayerPrivateAVFoundationObjC): (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad): Call clearTextTracks. (WebCore::MediaPlayerPrivateAVFoundationObjC::clearTextTracks): Remove all tracks from client. LayoutTests: Extend test to verify that all in-band tracks are removed from the media element when its src changes. * media/track/track-in-band-expected.txt: * media/track/track-in-band.html: git-svn-id: http://svn.webkit.org/repository/webkit/trunk@137844 268f45cc-cd09-0410-ab3c-d52691b4dbfc
b9acec69