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

Unified Diff: Source/modules/speech/SpeechRecognitionController.cpp

Issue 217323011: Apply OwnPtr|PassOwnPtr to handle member variables and arguments in SpeechRecognitionClient|Control… (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebased Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/modules/speech/SpeechRecognitionController.h ('k') | Source/web/WebViewImpl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/speech/SpeechRecognitionController.cpp
diff --git a/Source/modules/speech/SpeechRecognitionController.cpp b/Source/modules/speech/SpeechRecognitionController.cpp
index 47e12e05a50a8b1215e27b9137de5a2f123ac526..8abf2048b7d4c45806a09f5ebe1212319ecc75aa 100644
--- a/Source/modules/speech/SpeechRecognitionController.cpp
+++ b/Source/modules/speech/SpeechRecognitionController.cpp
@@ -33,7 +33,7 @@ const char* SpeechRecognitionController::supplementName()
return "SpeechRecognitionController";
}
-SpeechRecognitionController::SpeechRecognitionController(SpeechRecognitionClient* client)
+SpeechRecognitionController::SpeechRecognitionController(PassOwnPtr<SpeechRecognitionClient> client)
: m_client(client)
{
}
@@ -43,12 +43,12 @@ SpeechRecognitionController::~SpeechRecognitionController()
// FIXME: Call m_client->pageDestroyed(); once we have implemented a client.
}
-PassOwnPtr<SpeechRecognitionController> SpeechRecognitionController::create(SpeechRecognitionClient* client)
+PassOwnPtr<SpeechRecognitionController> SpeechRecognitionController::create(PassOwnPtr<SpeechRecognitionClient> client)
{
return adoptPtr(new SpeechRecognitionController(client));
}
-void provideSpeechRecognitionTo(Page& page, SpeechRecognitionClient* client)
+void provideSpeechRecognitionTo(Page& page, PassOwnPtr<SpeechRecognitionClient> client)
{
SpeechRecognitionController::provideTo(page, SpeechRecognitionController::supplementName(), SpeechRecognitionController::create(client));
}
« no previous file with comments | « Source/modules/speech/SpeechRecognitionController.h ('k') | Source/web/WebViewImpl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698