Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(64)

Side by Side Diff: third_party/WebKit/Source/core/html/track/VideoTrack.cpp

Issue 2050043002: Generate and assign media track ids in demuxers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@use-streamparser-trackid
Patch Set: rebase to ToT Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "core/html/track/VideoTrack.h" 5 #include "core/html/track/VideoTrack.h"
6 6
7 #include "core/html/HTMLMediaElement.h" 7 #include "core/html/HTMLMediaElement.h"
8 8
9 namespace blink { 9 namespace blink {
10 10
(...skipping 13 matching lines...) Expand all
24 } 24 }
25 25
26 void VideoTrack::setSelected(bool selected) 26 void VideoTrack::setSelected(bool selected)
27 { 27 {
28 if (selected == m_selected) 28 if (selected == m_selected)
29 return; 29 return;
30 30
31 m_selected = selected; 31 m_selected = selected;
32 32
33 if (mediaElement()) { 33 if (mediaElement()) {
34 WebMediaPlayer::TrackId selectedTrackId = trackId(); 34 WebMediaPlayer::TrackId selectedTrackId = id();
35 mediaElement()->selectedVideoTrackChanged(selected ? &selectedTrackId : 0); 35 mediaElement()->selectedVideoTrackChanged(selected ? &selectedTrackId : 0);
36 } 36 }
37 } 37 }
38 38
39 const AtomicString& VideoTrack::alternativeKeyword() 39 const AtomicString& VideoTrack::alternativeKeyword()
40 { 40 {
41 DEFINE_STATIC_LOCAL(const AtomicString, keyword, ("alternative")); 41 DEFINE_STATIC_LOCAL(const AtomicString, keyword, ("alternative"));
42 return keyword; 42 return keyword;
43 } 43 }
44 44
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 return kind == alternativeKeyword() 77 return kind == alternativeKeyword()
78 || kind == captionsKeyword() 78 || kind == captionsKeyword()
79 || kind == mainKeyword() 79 || kind == mainKeyword()
80 || kind == signKeyword() 80 || kind == signKeyword()
81 || kind == subtitlesKeyword() 81 || kind == subtitlesKeyword()
82 || kind == commentaryKeyword() 82 || kind == commentaryKeyword()
83 || kind == emptyAtom; 83 || kind == emptyAtom;
84 } 84 }
85 85
86 } // namespace blink 86 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698