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

Side by Side Diff: Source/core/html/MediaController.h

Issue 1219013005: Fix virtual/override/final usage in Source/core/html/. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 5 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
« no previous file with comments | « Source/core/html/LinkManifest.h ('k') | Source/core/html/MediaDocument.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Apple Inc. All rights reserved. 2 * Copyright (C) 2011 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 26 matching lines...) Expand all
37 class Clock; 37 class Clock;
38 class ExceptionState; 38 class ExceptionState;
39 class ExecutionContext; 39 class ExecutionContext;
40 class GenericEventQueue; 40 class GenericEventQueue;
41 41
42 class MediaController final : public EventTargetWithInlineData, public RefCounte dWillBeNoBase<MediaController> { 42 class MediaController final : public EventTargetWithInlineData, public RefCounte dWillBeNoBase<MediaController> {
43 DEFINE_WRAPPERTYPEINFO(); 43 DEFINE_WRAPPERTYPEINFO();
44 REFCOUNTED_EVENT_TARGET(MediaController); 44 REFCOUNTED_EVENT_TARGET(MediaController);
45 public: 45 public:
46 static PassRefPtrWillBeRawPtr<MediaController> create(ExecutionContext*); 46 static PassRefPtrWillBeRawPtr<MediaController> create(ExecutionContext*);
47 virtual ~MediaController(); 47 ~MediaController() override;
48 48
49 void addMediaElement(HTMLMediaElement*); 49 void addMediaElement(HTMLMediaElement*);
50 void removeMediaElement(HTMLMediaElement*); 50 void removeMediaElement(HTMLMediaElement*);
51 51
52 PassRefPtrWillBeRawPtr<TimeRanges> buffered() const; 52 PassRefPtrWillBeRawPtr<TimeRanges> buffered() const;
53 PassRefPtrWillBeRawPtr<TimeRanges> seekable() const; 53 PassRefPtrWillBeRawPtr<TimeRanges> seekable() const;
54 PassRefPtrWillBeRawPtr<TimeRanges> played(); 54 PassRefPtrWillBeRawPtr<TimeRanges> played();
55 55
56 double duration() const; 56 double duration() const;
57 double currentTime() const; 57 double currentTime() const;
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 void updateMediaElements(); 97 void updateMediaElements();
98 void bringElementUpToSpeed(HTMLMediaElement*); 98 void bringElementUpToSpeed(HTMLMediaElement*);
99 void scheduleEvent(const AtomicString& eventName); 99 void scheduleEvent(const AtomicString& eventName);
100 void clearPositionTimerFired(Timer<MediaController>*); 100 void clearPositionTimerFired(Timer<MediaController>*);
101 bool hasEnded() const; 101 bool hasEnded() const;
102 void scheduleTimeupdateEvent(); 102 void scheduleTimeupdateEvent();
103 void timeupdateTimerFired(Timer<MediaController>*); 103 void timeupdateTimerFired(Timer<MediaController>*);
104 void startTimeupdateTimer(); 104 void startTimeupdateTimer();
105 105
106 // EventTarget 106 // EventTarget
107 virtual const AtomicString& interfaceName() const override; 107 const AtomicString& interfaceName() const override;
108 virtual ExecutionContext* executionContext() const override { return m_execu tionContext; } 108 ExecutionContext* executionContext() const override { return m_executionCont ext; }
109 109
110 friend class HTMLMediaElement; 110 friend class HTMLMediaElement;
111 friend class MediaControllerEventListener; 111 friend class MediaControllerEventListener;
112 // FIXME: A MediaController should ideally keep an otherwise 112 // FIXME: A MediaController should ideally keep an otherwise
113 // unreferenced slaved media element alive. When Oilpan is 113 // unreferenced slaved media element alive. When Oilpan is
114 // enabled by default, consider making the hash set references 114 // enabled by default, consider making the hash set references
115 // strong to accomplish that. crbug.com/383072 115 // strong to accomplish that. crbug.com/383072
116 typedef WillBeHeapLinkedHashSet<RawPtrWillBeWeakMember<HTMLMediaElement>> Me diaElementSequence; 116 typedef WillBeHeapLinkedHashSet<RawPtrWillBeWeakMember<HTMLMediaElement>> Me diaElementSequence;
117 MediaElementSequence m_mediaElements; 117 MediaElementSequence m_mediaElements;
118 bool m_paused; 118 bool m_paused;
119 double m_defaultPlaybackRate; 119 double m_defaultPlaybackRate;
120 double m_volume; 120 double m_volume;
121 mutable double m_position; 121 mutable double m_position;
122 bool m_muted; 122 bool m_muted;
123 ReadyState m_readyState; 123 ReadyState m_readyState;
124 PlaybackState m_playbackState; 124 PlaybackState m_playbackState;
125 OwnPtrWillBeMember<GenericEventQueue> m_pendingEventsQueue; 125 OwnPtrWillBeMember<GenericEventQueue> m_pendingEventsQueue;
126 mutable Timer<MediaController> m_clearPositionTimer; 126 mutable Timer<MediaController> m_clearPositionTimer;
127 OwnPtr<Clock> m_clock; 127 OwnPtr<Clock> m_clock;
128 RawPtrWillBeWeakMember<ExecutionContext> m_executionContext; 128 RawPtrWillBeWeakMember<ExecutionContext> m_executionContext;
129 Timer<MediaController> m_timeupdateTimer; 129 Timer<MediaController> m_timeupdateTimer;
130 double m_previousTimeupdateTime; 130 double m_previousTimeupdateTime;
131 }; 131 };
132 132
133 } // namespace blink 133 } // namespace blink
134 134
135 #endif // MediaController_h 135 #endif // MediaController_h
OLDNEW
« no previous file with comments | « Source/core/html/LinkManifest.h ('k') | Source/core/html/MediaDocument.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698