| OLD | NEW |
| 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 #ifndef ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ | 5 #ifndef ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ |
| 6 #define ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ | 6 #define ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ |
| 7 | 7 |
| 8 #include "android_webview/browser/aw_download_manager_delegate.h" | 8 #include "android_webview/browser/aw_download_manager_delegate.h" |
| 9 #include "base/file_path.h" | 9 #include "base/file_path.h" |
| 10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
| 11 #include "content/public/browser/browser_context.h" | 11 #include "content/public/browser/browser_context.h" |
| 12 #include "content/public/browser/geolocation_permission_context.h" |
| 12 | 13 |
| 13 namespace android_webview { | 14 namespace android_webview { |
| 14 | 15 |
| 15 class AwURLRequestContextGetter; | 16 class AwURLRequestContextGetter; |
| 16 | 17 |
| 17 class AwBrowserContext : public content::BrowserContext { | 18 class AwBrowserContext : public content::BrowserContext { |
| 18 public: | 19 public: |
| 19 AwBrowserContext(const FilePath path); | 20 AwBrowserContext(const FilePath path); |
| 20 virtual ~AwBrowserContext(); | 21 virtual ~AwBrowserContext(); |
| 21 | 22 |
| (...skipping 16 matching lines...) Expand all Loading... |
| 38 const FilePath& partition_path, bool in_memory) OVERRIDE; | 39 const FilePath& partition_path, bool in_memory) OVERRIDE; |
| 39 virtual content::ResourceContext* GetResourceContext() OVERRIDE; | 40 virtual content::ResourceContext* GetResourceContext() OVERRIDE; |
| 40 virtual content::DownloadManagerDelegate* | 41 virtual content::DownloadManagerDelegate* |
| 41 GetDownloadManagerDelegate() OVERRIDE; | 42 GetDownloadManagerDelegate() OVERRIDE; |
| 42 virtual content::GeolocationPermissionContext* | 43 virtual content::GeolocationPermissionContext* |
| 43 GetGeolocationPermissionContext() OVERRIDE; | 44 GetGeolocationPermissionContext() OVERRIDE; |
| 44 virtual content::SpeechRecognitionPreferences* | 45 virtual content::SpeechRecognitionPreferences* |
| 45 GetSpeechRecognitionPreferences() OVERRIDE; | 46 GetSpeechRecognitionPreferences() OVERRIDE; |
| 46 virtual quota::SpecialStoragePolicy* GetSpecialStoragePolicy() OVERRIDE; | 47 virtual quota::SpecialStoragePolicy* GetSpecialStoragePolicy() OVERRIDE; |
| 47 | 48 |
| 49 // AwBrowserContext specific |
| 50 void set_geolocation_permissions_context( |
| 51 content::GeolocationPermissionContext* geolocation_permission_context); |
| 52 |
| 48 private: | 53 private: |
| 49 | 54 |
| 50 // The file path where data for this context is persisted. | 55 // The file path where data for this context is persisted. |
| 51 FilePath context_storage_path_; | 56 FilePath context_storage_path_; |
| 52 | 57 |
| 53 scoped_refptr<AwURLRequestContextGetter> url_request_context_getter_; | 58 scoped_refptr<AwURLRequestContextGetter> url_request_context_getter_; |
| 59 scoped_refptr<content::GeolocationPermissionContext> |
| 60 geolocation_permission_context_; |
| 54 | 61 |
| 55 AwDownloadManagerDelegate download_manager_delegate_; | 62 AwDownloadManagerDelegate download_manager_delegate_; |
| 56 | 63 |
| 57 DISALLOW_COPY_AND_ASSIGN(AwBrowserContext); | 64 DISALLOW_COPY_AND_ASSIGN(AwBrowserContext); |
| 58 }; | 65 }; |
| 59 | 66 |
| 60 } // namespace android_webview | 67 } // namespace android_webview |
| 61 | 68 |
| 62 #endif // ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ | 69 #endif // ANDROID_WEBVIEW_BROWSER_AW_BROWSER_CONTEXT_H_ |
| OLD | NEW |