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

Side by Side Diff: third_party/WebKit/Source/modules/mediastream/MediaStreamTrack.cpp

Issue 1805843002: [v8 gc] Introduce a base class for all objects that can have pending activity (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: updates Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * Copyright (C) 2011 Ericsson AB. All rights reserved. 3 * Copyright (C) 2011 Ericsson AB. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 namespace blink { 42 namespace blink {
43 43
44 MediaStreamTrack* MediaStreamTrack::create(ExecutionContext* context, MediaStrea mComponent* component) 44 MediaStreamTrack* MediaStreamTrack::create(ExecutionContext* context, MediaStrea mComponent* component)
45 { 45 {
46 MediaStreamTrack* track = new MediaStreamTrack(context, component); 46 MediaStreamTrack* track = new MediaStreamTrack(context, component);
47 track->suspendIfNeeded(); 47 track->suspendIfNeeded();
48 return track; 48 return track;
49 } 49 }
50 50
51 MediaStreamTrack::MediaStreamTrack(ExecutionContext* context, MediaStreamCompone nt* component) 51 MediaStreamTrack::MediaStreamTrack(ExecutionContext* context, MediaStreamCompone nt* component)
52 : ActiveDOMObject(context) 52 : ActiveScriptWrappable(this)
53 , ActiveDOMObject(context)
53 , m_readyState(MediaStreamSource::ReadyStateLive) 54 , m_readyState(MediaStreamSource::ReadyStateLive)
54 , m_isIteratingRegisteredMediaStreams(false) 55 , m_isIteratingRegisteredMediaStreams(false)
55 , m_stopped(false) 56 , m_stopped(false)
56 , m_component(component) 57 , m_component(component)
57 { 58 {
58 m_component->source()->addObserver(this); 59 m_component->source()->addObserver(this);
59 } 60 }
60 61
61 MediaStreamTrack::~MediaStreamTrack() 62 MediaStreamTrack::~MediaStreamTrack()
62 { 63 {
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after
259 260
260 DEFINE_TRACE(MediaStreamTrack) 261 DEFINE_TRACE(MediaStreamTrack)
261 { 262 {
262 visitor->trace(m_registeredMediaStreams); 263 visitor->trace(m_registeredMediaStreams);
263 visitor->trace(m_component); 264 visitor->trace(m_component);
264 RefCountedGarbageCollectedEventTargetWithInlineData<MediaStreamTrack>::trace (visitor); 265 RefCountedGarbageCollectedEventTargetWithInlineData<MediaStreamTrack>::trace (visitor);
265 ActiveDOMObject::trace(visitor); 266 ActiveDOMObject::trace(visitor);
266 } 267 }
267 268
268 } // namespace blink 269 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698