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

Side by Side Diff: third_party/WebKit/Source/modules/mediastream/MediaDevices.h

Issue 2577053002: ActiveScriptWrappable: GC wrappers in detached ExecutionContexts. (Closed)
Patch Set: component build fix(msvc) Created 4 years 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 #ifndef MediaDevices_h 5 #ifndef MediaDevices_h
6 #define MediaDevices_h 6 #define MediaDevices_h
7 7
8 #include "bindings/core/v8/ActiveScriptWrappable.h" 8 #include "bindings/core/v8/ActiveScriptWrappable.h"
9 #include "bindings/core/v8/ScriptPromise.h" 9 #include "bindings/core/v8/ScriptPromise.h"
10 #include "core/dom/SuspendableObject.h" 10 #include "core/dom/SuspendableObject.h"
11 #include "core/events/EventTarget.h" 11 #include "core/events/EventTarget.h"
12 #include "modules/EventTargetModules.h" 12 #include "modules/EventTargetModules.h"
13 #include "modules/ModulesExport.h" 13 #include "modules/ModulesExport.h"
14 #include "platform/AsyncMethodRunner.h" 14 #include "platform/AsyncMethodRunner.h"
15 15
16 namespace blink { 16 namespace blink {
17 17
18 class MediaStreamConstraints; 18 class MediaStreamConstraints;
19 class MediaTrackSupportedConstraints; 19 class MediaTrackSupportedConstraints;
20 class ScriptState; 20 class ScriptState;
21 class UserMediaController; 21 class UserMediaController;
22 22
23 class MODULES_EXPORT MediaDevices final : public EventTargetWithInlineData, 23 class MODULES_EXPORT MediaDevices final
24 public ActiveScriptWrappable, 24 : public EventTargetWithInlineData,
25 public SuspendableObject { 25 public ActiveScriptWrappable<MediaDevices>,
26 public SuspendableObject {
26 USING_GARBAGE_COLLECTED_MIXIN(MediaDevices); 27 USING_GARBAGE_COLLECTED_MIXIN(MediaDevices);
27 DEFINE_WRAPPERTYPEINFO(); 28 DEFINE_WRAPPERTYPEINFO();
28 USING_PRE_FINALIZER(MediaDevices, dispose); 29 USING_PRE_FINALIZER(MediaDevices, dispose);
29 30
30 public: 31 public:
31 static MediaDevices* create(ExecutionContext*); 32 static MediaDevices* create(ExecutionContext*);
32 ~MediaDevices() override; 33 ~MediaDevices() override;
33 34
34 ScriptPromise enumerateDevices(ScriptState*); 35 ScriptPromise enumerateDevices(ScriptState*);
35 void getSupportedConstraints(MediaTrackSupportedConstraints& result) {} 36 void getSupportedConstraints(MediaTrackSupportedConstraints& result) {}
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 74
74 bool m_observing; 75 bool m_observing;
75 bool m_stopped; 76 bool m_stopped;
76 Member<AsyncMethodRunner<MediaDevices>> m_dispatchScheduledEventRunner; 77 Member<AsyncMethodRunner<MediaDevices>> m_dispatchScheduledEventRunner;
77 HeapVector<Member<Event>> m_scheduledEvents; 78 HeapVector<Member<Event>> m_scheduledEvents;
78 }; 79 };
79 80
80 } // namespace blink 81 } // namespace blink
81 82
82 #endif 83 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698