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

Unified Diff: Source/modules/mediastream/UserMediaRequest.cpp

Issue 173363002: Move mediastream module to oilpan transition types (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: Source/modules/mediastream/UserMediaRequest.cpp
diff --git a/Source/modules/mediastream/UserMediaRequest.cpp b/Source/modules/mediastream/UserMediaRequest.cpp
index d031725b652ef2962be93f8f44bb53813a60c806..b543af093fb84b41f4e68a6cdab61c63cd647a0c 100644
--- a/Source/modules/mediastream/UserMediaRequest.cpp
+++ b/Source/modules/mediastream/UserMediaRequest.cpp
@@ -65,7 +65,7 @@ static blink::WebMediaConstraints parseOptions(const Dictionary& options, const
return constraints;
}
-PassRefPtr<UserMediaRequest> UserMediaRequest::create(ExecutionContext* context, UserMediaController* controller, const Dictionary& options, PassOwnPtr<NavigatorUserMediaSuccessCallback> successCallback, PassOwnPtr<NavigatorUserMediaErrorCallback> errorCallback, ExceptionState& exceptionState)
+PassRefPtrWillBeRawPtr<UserMediaRequest> UserMediaRequest::create(ExecutionContext* context, UserMediaController* controller, const Dictionary& options, PassOwnPtr<NavigatorUserMediaSuccessCallback> successCallback, PassOwnPtr<NavigatorUserMediaErrorCallback> errorCallback, ExceptionState& exceptionState)
{
blink::WebMediaConstraints audio = parseOptions(options, "audio", exceptionState);
if (exceptionState.hadException())
@@ -80,7 +80,7 @@ PassRefPtr<UserMediaRequest> UserMediaRequest::create(ExecutionContext* context,
return nullptr;
}
- return adoptRef(new UserMediaRequest(context, controller, audio, video, successCallback, errorCallback));
+ return adoptRefWillBeNoop(new UserMediaRequest(context, controller, audio, video, successCallback, errorCallback));
}
UserMediaRequest::UserMediaRequest(ExecutionContext* context, UserMediaController* controller, blink::WebMediaConstraints audio, blink::WebMediaConstraints video, PassOwnPtr<NavigatorUserMediaSuccessCallback> successCallback, PassOwnPtr<NavigatorUserMediaErrorCallback> errorCallback)
@@ -137,7 +137,7 @@ void UserMediaRequest::succeed(PassRefPtr<MediaStreamDescriptor> streamDescripto
if (!executionContext())
return;
- RefPtr<MediaStream> stream = MediaStream::create(executionContext(), streamDescriptor);
+ RefPtrWillBeRawPtr<MediaStream> stream = MediaStream::create(executionContext(), streamDescriptor);
MediaStreamTrackVector audioTracks = stream->getAudioTracks();
for (MediaStreamTrackVector::iterator iter = audioTracks.begin(); iter != audioTracks.end(); ++iter) {
@@ -157,7 +157,7 @@ void UserMediaRequest::failPermissionDenied(const String& message)
if (!executionContext())
return;
- RefPtr<NavigatorUserMediaError> error = NavigatorUserMediaError::create(NavigatorUserMediaError::NamePermissionDenied, message, String());
+ RefPtrWillBeRawPtr<NavigatorUserMediaError> error = NavigatorUserMediaError::create(NavigatorUserMediaError::NamePermissionDenied, message, String());
m_errorCallback->handleEvent(error.get());
}
@@ -167,7 +167,7 @@ void UserMediaRequest::failConstraint(const String& constraintName, const String
if (!executionContext())
return;
- RefPtr<NavigatorUserMediaError> error = NavigatorUserMediaError::create(NavigatorUserMediaError::NameConstraintNotSatisfied, message, constraintName);
+ RefPtrWillBeRawPtr<NavigatorUserMediaError> error = NavigatorUserMediaError::create(NavigatorUserMediaError::NameConstraintNotSatisfied, message, constraintName);
m_errorCallback->handleEvent(error.get());
}
@@ -177,13 +177,13 @@ void UserMediaRequest::failUASpecific(const String& name, const String& message,
if (!executionContext())
return;
- RefPtr<NavigatorUserMediaError> error = NavigatorUserMediaError::create(name, message, constraintName);
+ RefPtrWillBeRawPtr<NavigatorUserMediaError> error = NavigatorUserMediaError::create(name, message, constraintName);
m_errorCallback->handleEvent(error.get());
}
void UserMediaRequest::contextDestroyed()
{
- RefPtr<UserMediaRequest> protect(this);
+ RefPtrWillBeRawPtr<UserMediaRequest> protect(this);
if (m_controller) {
m_controller->cancelUserMediaRequest(this);

Powered by Google App Engine
This is Rietveld 408576698