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

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

Issue 2050123002: Remove OwnPtr from Blink. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: First attempt to land. Created 4 years, 6 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 17 matching lines...) Expand all
28 28
29 #include "bindings/core/v8/ActiveScriptWrappable.h" 29 #include "bindings/core/v8/ActiveScriptWrappable.h"
30 #include "core/dom/ActiveDOMObject.h" 30 #include "core/dom/ActiveDOMObject.h"
31 #include "modules/EventTargetModules.h" 31 #include "modules/EventTargetModules.h"
32 #include "modules/ModulesExport.h" 32 #include "modules/ModulesExport.h"
33 #include "modules/mediastream/SourceInfo.h" 33 #include "modules/mediastream/SourceInfo.h"
34 #include "platform/mediastream/MediaStreamDescriptor.h" 34 #include "platform/mediastream/MediaStreamDescriptor.h"
35 #include "platform/mediastream/MediaStreamSource.h" 35 #include "platform/mediastream/MediaStreamSource.h"
36 #include "public/platform/WebMediaConstraints.h" 36 #include "public/platform/WebMediaConstraints.h"
37 #include "wtf/Forward.h" 37 #include "wtf/Forward.h"
38 #include <memory>
38 39
39 namespace blink { 40 namespace blink {
40 41
41 class AudioSourceProvider; 42 class AudioSourceProvider;
42 class ExceptionState; 43 class ExceptionState;
43 class MediaTrackConstraints; 44 class MediaTrackConstraints;
44 class MediaStreamTrackSourcesCallback; 45 class MediaStreamTrackSourcesCallback;
45 class MediaTrackSettings; 46 class MediaTrackSettings;
46 47
47 class MODULES_EXPORT MediaStreamTrack 48 class MODULES_EXPORT MediaStreamTrack
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 // EventTarget 93 // EventTarget
93 const AtomicString& interfaceName() const override; 94 const AtomicString& interfaceName() const override;
94 ExecutionContext* getExecutionContext() const override; 95 ExecutionContext* getExecutionContext() const override;
95 96
96 // ActiveScriptWrappable 97 // ActiveScriptWrappable
97 bool hasPendingActivity() const final; 98 bool hasPendingActivity() const final;
98 99
99 // ActiveDOMObject 100 // ActiveDOMObject
100 void stop() override; 101 void stop() override;
101 102
102 PassOwnPtr<AudioSourceProvider> createWebAudioSource(); 103 std::unique_ptr<AudioSourceProvider> createWebAudioSource();
103 104
104 DECLARE_VIRTUAL_TRACE(); 105 DECLARE_VIRTUAL_TRACE();
105 106
106 private: 107 private:
107 friend class CanvasCaptureMediaStreamTrack; 108 friend class CanvasCaptureMediaStreamTrack;
108 109
109 MediaStreamTrack(ExecutionContext*, MediaStreamComponent*); 110 MediaStreamTrack(ExecutionContext*, MediaStreamComponent*);
110 111
111 // MediaStreamSourceObserver 112 // MediaStreamSourceObserver
112 void sourceChangedState() override; 113 void sourceChangedState() override;
113 114
114 void propagateTrackEnded(); 115 void propagateTrackEnded();
115 116
116 MediaStreamSource::ReadyState m_readyState; 117 MediaStreamSource::ReadyState m_readyState;
117 HeapHashSet<Member<MediaStream>> m_registeredMediaStreams; 118 HeapHashSet<Member<MediaStream>> m_registeredMediaStreams;
118 bool m_isIteratingRegisteredMediaStreams; 119 bool m_isIteratingRegisteredMediaStreams;
119 bool m_stopped; 120 bool m_stopped;
120 Member<MediaStreamComponent> m_component; 121 Member<MediaStreamComponent> m_component;
121 WebMediaConstraints m_constraints; 122 WebMediaConstraints m_constraints;
122 }; 123 };
123 124
124 typedef HeapVector<Member<MediaStreamTrack>> MediaStreamTrackVector; 125 typedef HeapVector<Member<MediaStreamTrack>> MediaStreamTrackVector;
125 126
126 } // namespace blink 127 } // namespace blink
127 128
128 #endif // MediaStreamTrack_h 129 #endif // MediaStreamTrack_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698