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

Side by Side Diff: Source/modules/mediastream/UserMediaRequest.cpp

Issue 552653005: Oilpan: Move MediaStreamSource, MediaStreamComponent and MediaStreamDescriptor to oilpan's heap (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 2 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Ericsson AB. All rights reserved. 2 * Copyright (C) 2011 Ericsson AB. All rights reserved.
3 * Copyright (C) 2012 Google Inc. All rights reserved. 3 * Copyright (C) 2012 Google Inc. 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 * 8 *
9 * 1. Redistributions of source code must retain the above copyright 9 * 1. Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer. 10 * notice, this list of conditions and the following disclaimer.
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 125
126 return 0; 126 return 0;
127 } 127 }
128 128
129 void UserMediaRequest::start() 129 void UserMediaRequest::start()
130 { 130 {
131 if (m_controller) 131 if (m_controller)
132 m_controller->requestUserMedia(this); 132 m_controller->requestUserMedia(this);
133 } 133 }
134 134
135 void UserMediaRequest::succeed(PassRefPtr<MediaStreamDescriptor> streamDescripto r) 135 void UserMediaRequest::succeed(MediaStreamDescriptor* streamDescriptor)
136 { 136 {
137 if (!executionContext()) 137 if (!executionContext())
138 return; 138 return;
139 139
140 RefPtrWillBeRawPtr<MediaStream> stream = MediaStream::create(executionContex t(), streamDescriptor); 140 RefPtrWillBeRawPtr<MediaStream> stream = MediaStream::create(executionContex t(), streamDescriptor);
141 141
142 MediaStreamTrackVector audioTracks = stream->getAudioTracks(); 142 MediaStreamTrackVector audioTracks = stream->getAudioTracks();
143 for (MediaStreamTrackVector::iterator iter = audioTracks.begin(); iter != au dioTracks.end(); ++iter) { 143 for (MediaStreamTrackVector::iterator iter = audioTracks.begin(); iter != au dioTracks.end(); ++iter) {
144 (*iter)->component()->source()->setConstraints(m_audio); 144 (*iter)->component()->source()->setConstraints(m_audio);
145 } 145 }
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
185 ContextLifecycleObserver::contextDestroyed(); 185 ContextLifecycleObserver::contextDestroyed();
186 } 186 }
187 187
188 void UserMediaRequest::trace(Visitor* visitor) 188 void UserMediaRequest::trace(Visitor* visitor)
189 { 189 {
190 visitor->trace(m_successCallback); 190 visitor->trace(m_successCallback);
191 visitor->trace(m_errorCallback); 191 visitor->trace(m_errorCallback);
192 } 192 }
193 193
194 } // namespace blink 194 } // namespace blink
OLDNEW
« no previous file with comments | « Source/modules/mediastream/UserMediaRequest.h ('k') | Source/modules/webaudio/MediaStreamAudioDestinationNode.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698