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

Side by Side Diff: Source/core/html/track/TextTrackList.h

Issue 177243018: Prevent 'removetrack' events from firing when all inband text tracks are removed. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Fix expectations Created 6 years, 9 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 virtual ~TextTrackList(); 51 virtual ~TextTrackList();
52 52
53 unsigned length() const; 53 unsigned length() const;
54 int getTrackIndex(TextTrack*); 54 int getTrackIndex(TextTrack*);
55 int getTrackIndexRelativeToRenderedTracks(TextTrack*); 55 int getTrackIndexRelativeToRenderedTracks(TextTrack*);
56 bool contains(TextTrack*) const; 56 bool contains(TextTrack*) const;
57 57
58 TextTrack* item(unsigned index); 58 TextTrack* item(unsigned index);
59 TextTrack* getTrackById(const AtomicString& id); 59 TextTrack* getTrackById(const AtomicString& id);
60 void append(PassRefPtr<TextTrack>); 60 void append(PassRefPtr<TextTrack>);
61 void remove(TextTrack*); 61 void remove(TextTrack*, bool scheduleEvent);
62 62
63 // EventTarget 63 // EventTarget
64 virtual const AtomicString& interfaceName() const OVERRIDE; 64 virtual const AtomicString& interfaceName() const OVERRIDE;
65 virtual ExecutionContext* executionContext() const OVERRIDE; 65 virtual ExecutionContext* executionContext() const OVERRIDE;
66 66
67 DEFINE_ATTRIBUTE_EVENT_LISTENER(addtrack); 67 DEFINE_ATTRIBUTE_EVENT_LISTENER(addtrack);
68 DEFINE_ATTRIBUTE_EVENT_LISTENER(change); 68 DEFINE_ATTRIBUTE_EVENT_LISTENER(change);
69 DEFINE_ATTRIBUTE_EVENT_LISTENER(removetrack); 69 DEFINE_ATTRIBUTE_EVENT_LISTENER(removetrack);
70 70
71 void clearOwnerAndClients(); 71 void clearOwnerAndClients();
(...skipping 16 matching lines...) Expand all
88 OwnPtr<GenericEventQueue> m_asyncEventQueue; 88 OwnPtr<GenericEventQueue> m_asyncEventQueue;
89 89
90 Vector<RefPtr<TextTrack> > m_addTrackTracks; 90 Vector<RefPtr<TextTrack> > m_addTrackTracks;
91 Vector<RefPtr<TextTrack> > m_elementTracks; 91 Vector<RefPtr<TextTrack> > m_elementTracks;
92 Vector<RefPtr<TextTrack> > m_inbandTracks; 92 Vector<RefPtr<TextTrack> > m_inbandTracks;
93 }; 93 };
94 94
95 } // namespace WebCore 95 } // namespace WebCore
96 96
97 #endif 97 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698