| Index: Source/core/html/track/TrackBase.cpp
|
| diff --git a/Source/core/html/track/TrackBase.cpp b/Source/core/html/track/TrackBase.cpp
|
| index a11c065f41080f3d1d9d5b8d9e5b8b5c4a43105d..4ca6a29dda42a09e9c7271977ed1810e03885d5d 100644
|
| --- a/Source/core/html/track/TrackBase.cpp
|
| +++ b/Source/core/html/track/TrackBase.cpp
|
| @@ -33,16 +33,27 @@
|
|
|
| namespace WebCore {
|
|
|
| -TrackBase::TrackBase(Type type, const AtomicString& label, const AtomicString& language, const AtomicString& id)
|
| - : m_type(type)
|
| +static blink::WebMediaPlayer::TrackId nextTrackId()
|
| +{
|
| + static blink::WebMediaPlayer::TrackId next = 0;
|
| + return ++next;
|
| +}
|
| +
|
| +TrackBase::TrackBase(Type type, const AtomicString& label, const AtomicString& language, const String& id)
|
| + : m_trackId(nextTrackId())
|
| + , m_type(type)
|
| , m_label(label)
|
| , m_language(language)
|
| , m_id(id)
|
| + , m_mediaElement(nullptr)
|
| {
|
| }
|
|
|
| TrackBase::~TrackBase()
|
| {
|
| +#if !ENABLE(OILPAN)
|
| + ASSERT(!m_mediaElement);
|
| +#endif
|
| }
|
|
|
| void TrackBase::setKind(const AtomicString& kind)
|
| @@ -54,4 +65,3 @@ void TrackBase::setKind(const AtomicString& kind)
|
| }
|
|
|
| } // namespace WebCore
|
| -
|
|
|