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

Unified Diff: android_webview/browser/aw_browser_context.cc

Issue 16907002: Update Android to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | android_webview/browser/aw_content_browser_client.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: android_webview/browser/aw_browser_context.cc
diff --git a/android_webview/browser/aw_browser_context.cc b/android_webview/browser/aw_browser_context.cc
index 8f0f214d13b08ef1578edf46cbe2bfc73aefd479..ea98457e960116ddec917e6e7cb25047b3d86bda 100644
--- a/android_webview/browser/aw_browser_context.cc
+++ b/android_webview/browser/aw_browser_context.cc
@@ -61,7 +61,7 @@ AwBrowserContext* AwBrowserContext::FromWebContents(
}
void AwBrowserContext::InitializeBeforeThreadCreation() {
- DCHECK(!url_request_context_getter_);
+ DCHECK(!url_request_context_getter_.get());
url_request_context_getter_ = new AwURLRequestContextGetter(this);
}
@@ -78,7 +78,7 @@ void AwBrowserContext::AddVisitedURLs(const std::vector<GURL>& urls) {
net::URLRequestContextGetter* AwBrowserContext::CreateRequestContext(
content::ProtocolHandlerMap* protocol_handlers) {
- CHECK(url_request_context_getter_);
+ CHECK(url_request_context_getter_.get());
url_request_context_getter_->SetProtocolHandlers(protocol_handlers);
return url_request_context_getter_.get();
}
@@ -88,7 +88,7 @@ AwBrowserContext::CreateRequestContextForStoragePartition(
const base::FilePath& partition_path,
bool in_memory,
content::ProtocolHandlerMap* protocol_handlers) {
- CHECK(url_request_context_getter_);
+ CHECK(url_request_context_getter_.get());
return url_request_context_getter_.get();
}
@@ -159,9 +159,9 @@ AwBrowserContext::GetMediaRequestContextForStoragePartition(
content::ResourceContext* AwBrowserContext::GetResourceContext() {
if (!resource_context_) {
- CHECK(url_request_context_getter_);
- resource_context_.reset(new AwResourceContext(
- url_request_context_getter_.get()));
+ CHECK(url_request_context_getter_.get());
+ resource_context_.reset(
+ new AwResourceContext(url_request_context_getter_.get()));
}
return resource_context_.get();
}
@@ -173,11 +173,11 @@ AwBrowserContext::GetDownloadManagerDelegate() {
content::GeolocationPermissionContext*
AwBrowserContext::GetGeolocationPermissionContext() {
- if (!geolocation_permission_context_) {
+ if (!geolocation_permission_context_.get()) {
geolocation_permission_context_ =
native_factory_->CreateGeolocationPermission(this);
}
- return geolocation_permission_context_;
+ return geolocation_permission_context_.get();
}
content::SpeechRecognitionPreferences*
« no previous file with comments | « no previous file | android_webview/browser/aw_content_browser_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698