Commit 1c81affb authored by jer.noble@apple.com's avatar jer.noble@apple.com

Unreviewed build fix; The addedFunction and removedFunction arguments to...

Unreviewed build fix; The addedFunction and removedFunction arguments to determineChangedTracksFromNewTracksAndOldItems
were reversed, exposing an underlying, existing bug in AudioTrackPrivate and VideoTrack private. Give a default (null)
value to AudioTrackPrivate::m_client and VideoTrackPrivate::m_client and fix the ordering of arguments in
determineChangedTracksFromNewTracksAndOldItems.

* platform/graphics/AudioTrackPrivate.h:
(WebCore::AudioTrackPrivate::AudioTrackPrivate):
* platform/graphics/VideoTrackPrivate.h:
(WebCore::VideoTrackPrivate::VideoTrackPrivate):
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::determineChangedTracksFromNewTracksAndOldItems):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@156726 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent ba082ec1
2013-10-01 Jer Noble <jer.noble@apple.com>
Unreviewed build fix; The addedFunction and removedFunction arguments to determineChangedTracksFromNewTracksAndOldItems
were reversed, exposing an underlying, existing bug in AudioTrackPrivate and VideoTrack private. Give a default (null)
value to AudioTrackPrivate::m_client and VideoTrackPrivate::m_client and fix the ordering of arguments in
determineChangedTracksFromNewTracksAndOldItems.
* platform/graphics/AudioTrackPrivate.h:
(WebCore::AudioTrackPrivate::AudioTrackPrivate):
* platform/graphics/VideoTrackPrivate.h:
(WebCore::VideoTrackPrivate::VideoTrackPrivate):
* platform/graphics/avfoundation/objc/MediaPlayerPrivateAVFoundationObjC.mm:
(WebCore::determineChangedTracksFromNewTracksAndOldItems):
2013-09-30 Jer Noble <jer.noble@apple.com>
[Mac] Add support for VideoTrack to MediaPlayerPrivateAVFObjC
......@@ -75,7 +75,8 @@ public:
protected:
AudioTrackPrivate()
: m_enabled(false)
: m_client(0)
, m_enabled(false)
{
}
......
......@@ -75,7 +75,8 @@ public:
protected:
VideoTrackPrivate()
: m_selected(false)
: m_client(0)
, m_selected(false)
{
}
......
......@@ -1090,7 +1090,7 @@ void MediaPlayerPrivateAVFoundationObjC::tracksChanged()
#if ENABLE(VIDEO_TRACK)
template <typename RefT, typename PassRefT>
void determineChangedTracksFromNewTracksAndOldItems(NSArray* tracks, NSString* trackType, Vector<RefT>& oldItems, RefT (*itemFactory)(AVPlayerItemTrack*), MediaPlayer* player, void (MediaPlayer::*addedFunction)(PassRefT), void (MediaPlayer::*removedFunction)(PassRefT))
void determineChangedTracksFromNewTracksAndOldItems(NSArray* tracks, NSString* trackType, Vector<RefT>& oldItems, RefT (*itemFactory)(AVPlayerItemTrack*), MediaPlayer* player, void (MediaPlayer::*removedFunction)(PassRefT), void (MediaPlayer::*addedFunction)(PassRefT))
{
RetainPtr<NSSet> newTracks = adoptNS([[NSSet alloc] initWithArray:[tracks objectsAtIndexes:[tracks indexesOfObjectsPassingTest:^(id track, NSUInteger, BOOL*){
return [[[track assetTrack] mediaType] isEqualToString:trackType];
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment