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

Side by Side Diff: android_webview/browser/aw_browser_context.cc

Issue 11763002: Implementing native chromium GeolocationPermissionContext (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Passing AwGeolocationPermission to the ctor Created 7 years, 11 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 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "android_webview/browser/aw_browser_context.h" 5 #include "android_webview/browser/aw_browser_context.h"
6 6
7 #include "android_webview/browser/net/aw_url_request_context_getter.h" 7 #include "android_webview/browser/net/aw_url_request_context_getter.h"
8 8
9 namespace android_webview { 9 namespace android_webview {
10 10
11 AwBrowserContext::AwBrowserContext(const FilePath path) 11 AwBrowserContext::AwBrowserContext(
12 : context_storage_path_(path) { 12 const FilePath path,
13 content::GeolocationPermissionContext* geolocation_permission_context)
14 : context_storage_path_(path),
15 geolocation_permission_context_(geolocation_permission_context) {
13 } 16 }
14 17
15 AwBrowserContext::~AwBrowserContext() { 18 AwBrowserContext::~AwBrowserContext() {
16 } 19 }
17 20
18 void AwBrowserContext::InitializeBeforeThreadCreation() { 21 void AwBrowserContext::InitializeBeforeThreadCreation() {
19 DCHECK(!url_request_context_getter_); 22 DCHECK(!url_request_context_getter_);
20 url_request_context_getter_ = new AwURLRequestContextGetter(this); 23 url_request_context_getter_ = new AwURLRequestContextGetter(this);
21 } 24 }
22 25
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 return url_request_context_getter_->GetResourceContext(); 71 return url_request_context_getter_->GetResourceContext();
69 } 72 }
70 73
71 content::DownloadManagerDelegate* 74 content::DownloadManagerDelegate*
72 AwBrowserContext::GetDownloadManagerDelegate() { 75 AwBrowserContext::GetDownloadManagerDelegate() {
73 return &download_manager_delegate_; 76 return &download_manager_delegate_;
74 } 77 }
75 78
76 content::GeolocationPermissionContext* 79 content::GeolocationPermissionContext*
77 AwBrowserContext::GetGeolocationPermissionContext() { 80 AwBrowserContext::GetGeolocationPermissionContext() {
78 // TODO(boliu): Implement this to power WebSettings.setGeolocationEnabled 81 return geolocation_permission_context_;
79 // setting.
80 NOTIMPLEMENTED();
81 return NULL;
82 } 82 }
83 83
84 content::SpeechRecognitionPreferences* 84 content::SpeechRecognitionPreferences*
85 AwBrowserContext::GetSpeechRecognitionPreferences() { 85 AwBrowserContext::GetSpeechRecognitionPreferences() {
86 // By default allows profanities in speech recognition if return NULL. 86 // By default allows profanities in speech recognition if return NULL.
87 return NULL; 87 return NULL;
88 } 88 }
89 89
90 quota::SpecialStoragePolicy* AwBrowserContext::GetSpecialStoragePolicy() { 90 quota::SpecialStoragePolicy* AwBrowserContext::GetSpecialStoragePolicy() {
91 // TODO(boliu): Implement this so we are not relying on default behavior. 91 // TODO(boliu): Implement this so we are not relying on default behavior.
92 NOTIMPLEMENTED(); 92 NOTIMPLEMENTED();
93 return NULL; 93 return NULL;
94 } 94 }
95 95
96 } // namespace android_webview 96 } // namespace android_webview
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698