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

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

Issue 12211047: Implementing geolocation for the Android Webview (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Minor style updates Created 7 years, 10 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_content_browser_client.h" 5 #include "android_webview/browser/aw_content_browser_client.h"
6 6
7 #include "android_webview/browser/aw_browser_main_parts.h" 7 #include "android_webview/browser/aw_browser_main_parts.h"
8 #include "android_webview/browser/aw_cookie_access_policy.h" 8 #include "android_webview/browser/aw_cookie_access_policy.h"
9 #include "android_webview/browser/aw_quota_permission_context.h" 9 #include "android_webview/browser/aw_quota_permission_context.h"
10 #include "android_webview/browser/net_disk_cache_remover.h" 10 #include "android_webview/browser/net_disk_cache_remover.h"
11 #include "android_webview/browser/renderer_host/aw_resource_dispatcher_host_dele gate.h" 11 #include "android_webview/browser/renderer_host/aw_resource_dispatcher_host_dele gate.h"
12 #include "android_webview/common/url_constants.h" 12 #include "android_webview/common/url_constants.h"
13 #include "base/android/locale_utils.h" 13 #include "base/android/locale_utils.h"
14 #include "base/base_paths_android.h" 14 #include "base/base_paths_android.h"
15 #include "base/path_service.h" 15 #include "base/path_service.h"
16 #include "content/public/browser/access_token_store.h" 16 #include "content/public/browser/access_token_store.h"
17 #include "content/public/browser/child_process_security_policy.h" 17 #include "content/public/browser/child_process_security_policy.h"
18 #include "content/public/browser/render_process_host.h" 18 #include "content/public/browser/render_process_host.h"
19 #include "content/public/browser/render_view_host.h" 19 #include "content/public/browser/render_view_host.h"
20 #include "content/public/common/url_constants.h" 20 #include "content/public/common/url_constants.h"
21 #include "grit/ui_resources.h" 21 #include "grit/ui_resources.h"
22 #include "ui/base/resource/resource_bundle.h" 22 #include "ui/base/resource/resource_bundle.h"
23 23
24 namespace { 24 namespace {
25 25
26 class DummyAccessTokenStore : public content::AccessTokenStore { 26 class DummyAccessTokenStore : public content::AccessTokenStore {
boliu 2013/02/06 20:29:54 Rename this class now?
Kristian Monsen 2013/02/08 00:07:44 Renamed it to AwAccessTokenStore, but really not m
27 public: 27 public:
28 DummyAccessTokenStore() { } 28 DummyAccessTokenStore() { }
29 29
30 virtual void LoadAccessTokens( 30 virtual void LoadAccessTokens(
31 const LoadAccessTokensCallbackType& request) OVERRIDE { } 31 const LoadAccessTokensCallbackType& request) OVERRIDE {
32 request.Run(access_token_set_, NULL);
joth 2013/02/06 22:09:51 comment that access tokens not used on android, bu
Kristian Monsen 2013/02/08 00:07:44 Done.
33 }
32 34
33 private: 35 private:
34 virtual ~DummyAccessTokenStore() { } 36 virtual ~DummyAccessTokenStore() { }
35 37
36 virtual void SaveAccessToken( 38 virtual void SaveAccessToken(
boliu 2013/02/06 20:29:54 Really weird two overriden methods from same class
Kristian Monsen 2013/02/08 00:07:44 Done.
37 const GURL& server_url, const string16& access_token) OVERRIDE { } 39 const GURL& server_url, const string16& access_token) OVERRIDE { }
38 40
41 AccessTokenStore::AccessTokenSet access_token_set_;
joth 2013/02/06 22:09:51 I think you can make this a local in the method ab
Kristian Monsen 2013/02/08 00:07:44 Done.
42
39 DISALLOW_COPY_AND_ASSIGN(DummyAccessTokenStore); 43 DISALLOW_COPY_AND_ASSIGN(DummyAccessTokenStore);
40 }; 44 };
41 45
42 } 46 }
43 47
44 namespace android_webview { 48 namespace android_webview {
45 49
46 AwContentBrowserClient::AwContentBrowserClient( 50 AwContentBrowserClient::AwContentBrowserClient(
47 ViewDelegateFactoryFn* view_delegate_factory, 51 ViewDelegateFactoryFn* view_delegate_factory,
48 GeolocationPermissionFactoryFn* geolocation_permission_factory) 52 GeolocationPermissionFactoryFn* geolocation_permission_factory)
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 331
328 bool AwContentBrowserClient::AllowPepperSocketAPI( 332 bool AwContentBrowserClient::AllowPepperSocketAPI(
329 content::BrowserContext* browser_context, 333 content::BrowserContext* browser_context,
330 const GURL& url, 334 const GURL& url,
331 const content::SocketPermissionRequest& params) { 335 const content::SocketPermissionRequest& params) {
332 NOTREACHED() << "Android WebView does not support plugins"; 336 NOTREACHED() << "Android WebView does not support plugins";
333 return false; 337 return false;
334 } 338 }
335 339
336 } // namespace android_webview 340 } // namespace android_webview
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698