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

Side by Side Diff: third_party/WebKit/Source/modules/audio_output_devices/HTMLMediaElementAudioOutputDevice.cpp

Issue 1846913009: HeapSupplements are now just Supplements. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "modules/audio_output_devices/HTMLMediaElementAudioOutputDevice.h" 5 #include "modules/audio_output_devices/HTMLMediaElementAudioOutputDevice.h"
6 6
7 #include "bindings/core/v8/ScriptPromiseResolver.h" 7 #include "bindings/core/v8/ScriptPromiseResolver.h"
8 #include "bindings/core/v8/ScriptState.h" 8 #include "bindings/core/v8/ScriptState.h"
9 #include "core/dom/ExecutionContext.h" 9 #include "core/dom/ExecutionContext.h"
10 #include "modules/audio_output_devices/AudioOutputDeviceClient.h" 10 #include "modules/audio_output_devices/AudioOutputDeviceClient.h"
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 return promise; 110 return promise;
111 } 111 }
112 112
113 const char* HTMLMediaElementAudioOutputDevice::supplementName() 113 const char* HTMLMediaElementAudioOutputDevice::supplementName()
114 { 114 {
115 return "HTMLMediaElementAudioOutputDevice"; 115 return "HTMLMediaElementAudioOutputDevice";
116 } 116 }
117 117
118 HTMLMediaElementAudioOutputDevice& HTMLMediaElementAudioOutputDevice::from(HTMLM ediaElement& element) 118 HTMLMediaElementAudioOutputDevice& HTMLMediaElementAudioOutputDevice::from(HTMLM ediaElement& element)
119 { 119 {
120 HTMLMediaElementAudioOutputDevice* supplement = static_cast<HTMLMediaElement AudioOutputDevice*>(HeapSupplement<HTMLMediaElement>::from(element, supplementNa me())); 120 HTMLMediaElementAudioOutputDevice* supplement = static_cast<HTMLMediaElement AudioOutputDevice*>(Supplement<HTMLMediaElement>::from(element, supplementName() ));
121 if (!supplement) { 121 if (!supplement) {
122 supplement = new HTMLMediaElementAudioOutputDevice(); 122 supplement = new HTMLMediaElementAudioOutputDevice();
123 provideTo(element, supplementName(), supplement); 123 provideTo(element, supplementName(), supplement);
124 } 124 }
125 return *supplement; 125 return *supplement;
126 } 126 }
127 127
128 DEFINE_TRACE(HTMLMediaElementAudioOutputDevice) 128 DEFINE_TRACE(HTMLMediaElementAudioOutputDevice)
129 { 129 {
130 HeapSupplement<HTMLMediaElement>::trace(visitor); 130 Supplement<HTMLMediaElement>::trace(visitor);
131 } 131 }
132 132
133 } // namespace blink 133 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698