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
3 // found in the LICENSE file.
6 #include "core/html/track/AudioTrackList.h"
10 PassRefPtrWillBeRawPtr<AudioTrackList> AudioTrackList::create(HTMLMediaElement& mediaElement)
12 return adoptRefWillBeRefCountedGarbageCollected(new AudioTrackList(mediaElement));
15 AudioTrackList::~AudioTrackList()
19 AudioTrackList::AudioTrackList(HTMLMediaElement& mediaElement)
20 : TrackListBase<AudioTrack>(&mediaElement)
22 ScriptWrappable::init(this);
25 bool AudioTrackList::hasEnabledTrack() const
27 for (unsigned i = 0; i < length(); ++i) {
28 if (anonymousIndexedGetter(i)->enabled())
35 const AtomicString& AudioTrackList::interfaceName() const
37 return EventTargetNames::AudioTrackList;