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

Unified Diff: third_party/WebKit/Source/modules/mediastream/MediaStream.h

Issue 2549353005: Remove ContextLifecycleObserver from MediaStream (Closed)
Patch Set: temp 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/mediastream/MediaStream.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/mediastream/MediaStream.h
diff --git a/third_party/WebKit/Source/modules/mediastream/MediaStream.h b/third_party/WebKit/Source/modules/mediastream/MediaStream.h
index e3bca0afa86e4210c5714cc84482ad4785f7c7cc..d04cd2c2786603c89027acfee118ae1613cc16da 100644
--- a/third_party/WebKit/Source/modules/mediastream/MediaStream.h
+++ b/third_party/WebKit/Source/modules/mediastream/MediaStream.h
@@ -26,7 +26,7 @@
#ifndef MediaStream_h
#define MediaStream_h
-#include "core/dom/ContextLifecycleObserver.h"
+#include "core/dom/ExecutionContext.h"
#include "core/html/URLRegistry.h"
#include "modules/EventTargetModules.h"
#include "modules/ModulesExport.h"
@@ -40,8 +40,7 @@ class ExceptionState;
class MODULES_EXPORT MediaStream final : public EventTargetWithInlineData,
public URLRegistrable,
- public MediaStreamDescriptorClient,
- public ContextLifecycleObserver {
+ public MediaStreamDescriptorClient {
USING_GARBAGE_COLLECTED_MIXIN(MediaStream);
DEFINE_WRAPPERTYPEINFO();
@@ -79,7 +78,9 @@ class MODULES_EXPORT MediaStream final : public EventTargetWithInlineData,
// EventTarget
const AtomicString& interfaceName() const override;
- ExecutionContext* getExecutionContext() const override;
+ ExecutionContext* getExecutionContext() const override {
+ return m_executionContext;
+ }
// URLRegistrable
URLRegistry& registry() const override;
@@ -98,9 +99,6 @@ class MODULES_EXPORT MediaStream final : public EventTargetWithInlineData,
const MediaStreamTrackVector& audioTracks,
const MediaStreamTrackVector& videoTracks);
- // ContextLifecycleObserver
- void contextDestroyed() override;
-
// MediaStreamDescriptorClient
void addRemoteTrack(MediaStreamComponent*) override;
void removeRemoteTrack(MediaStreamComponent*) override;
@@ -110,14 +108,13 @@ class MODULES_EXPORT MediaStream final : public EventTargetWithInlineData,
void scheduleDispatchEvent(Event*);
void scheduledEventTimerFired(TimerBase*);
- bool m_stopped;
-
MediaStreamTrackVector m_audioTracks;
MediaStreamTrackVector m_videoTracks;
Member<MediaStreamDescriptor> m_descriptor;
Timer<MediaStream> m_scheduledEventTimer;
HeapVector<Member<Event>> m_scheduledEvents;
+ Member<ExecutionContext> m_executionContext;
haraken 2016/12/07 06:35:01 Before this CL, this was a weak member. However, I
sof 2016/12/07 07:34:16 the worry/difference would be that downstream user
haraken 2016/12/07 08:05:52 Yeah, good point. Currently EventTarget::getExecu
};
typedef HeapVector<Member<MediaStream>> MediaStreamVector;
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/mediastream/MediaStream.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698