| 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 #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_context.h" | 7 #include "android_webview/browser/aw_browser_context.h" |
| 8 #include "android_webview/browser/aw_browser_main_parts.h" | 8 #include "android_webview/browser/aw_browser_main_parts.h" |
| 9 #include "android_webview/browser/aw_contents_client_bridge_base.h" | 9 #include "android_webview/browser/aw_contents_client_bridge_base.h" |
| 10 #include "android_webview/browser/aw_cookie_access_policy.h" | 10 #include "android_webview/browser/aw_cookie_access_policy.h" |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 | 112 |
| 113 // content::AccessTokenStore implementation | 113 // content::AccessTokenStore implementation |
| 114 virtual void LoadAccessTokens( | 114 virtual void LoadAccessTokens( |
| 115 const LoadAccessTokensCallbackType& request) OVERRIDE { | 115 const LoadAccessTokensCallbackType& request) OVERRIDE { |
| 116 AccessTokenStore::AccessTokenSet access_token_set; | 116 AccessTokenStore::AccessTokenSet access_token_set; |
| 117 // AccessTokenSet and net::URLRequestContextGetter not used on Android, | 117 // AccessTokenSet and net::URLRequestContextGetter not used on Android, |
| 118 // but Run needs to be called to finish the geolocation setup. | 118 // but Run needs to be called to finish the geolocation setup. |
| 119 request.Run(access_token_set, NULL); | 119 request.Run(access_token_set, NULL); |
| 120 } | 120 } |
| 121 virtual void SaveAccessToken(const GURL& server_url, | 121 virtual void SaveAccessToken(const GURL& server_url, |
| 122 const string16& access_token) OVERRIDE { } | 122 const base::string16& access_token) OVERRIDE { } |
| 123 | 123 |
| 124 private: | 124 private: |
| 125 virtual ~AwAccessTokenStore() { } | 125 virtual ~AwAccessTokenStore() { } |
| 126 | 126 |
| 127 DISALLOW_COPY_AND_ASSIGN(AwAccessTokenStore); | 127 DISALLOW_COPY_AND_ASSIGN(AwAccessTokenStore); |
| 128 }; | 128 }; |
| 129 | 129 |
| 130 } | 130 } |
| 131 | 131 |
| 132 std::string AwContentBrowserClient::GetAcceptLangsImpl() { | 132 std::string AwContentBrowserClient::GetAcceptLangsImpl() { |
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 278 first_party, | 278 first_party, |
| 279 cookie_line, | 279 cookie_line, |
| 280 context, | 280 context, |
| 281 render_process_id, | 281 render_process_id, |
| 282 render_view_id, | 282 render_view_id, |
| 283 options); | 283 options); |
| 284 } | 284 } |
| 285 | 285 |
| 286 bool AwContentBrowserClient::AllowWorkerDatabase( | 286 bool AwContentBrowserClient::AllowWorkerDatabase( |
| 287 const GURL& url, | 287 const GURL& url, |
| 288 const string16& name, | 288 const base::string16& name, |
| 289 const string16& display_name, | 289 const base::string16& display_name, |
| 290 unsigned long estimated_size, | 290 unsigned long estimated_size, |
| 291 content::ResourceContext* context, | 291 content::ResourceContext* context, |
| 292 const std::vector<std::pair<int, int> >& render_frames) { | 292 const std::vector<std::pair<int, int> >& render_frames) { |
| 293 // Android WebView does not yet support web workers. | 293 // Android WebView does not yet support web workers. |
| 294 return false; | 294 return false; |
| 295 } | 295 } |
| 296 | 296 |
| 297 bool AwContentBrowserClient::AllowWorkerFileSystem( | 297 bool AwContentBrowserClient::AllowWorkerFileSystem( |
| 298 const GURL& url, | 298 const GURL& url, |
| 299 content::ResourceContext* context, | 299 content::ResourceContext* context, |
| 300 const std::vector<std::pair<int, int> >& render_frames) { | 300 const std::vector<std::pair<int, int> >& render_frames) { |
| 301 // Android WebView does not yet support web workers. | 301 // Android WebView does not yet support web workers. |
| 302 return false; | 302 return false; |
| 303 } | 303 } |
| 304 | 304 |
| 305 bool AwContentBrowserClient::AllowWorkerIndexedDB( | 305 bool AwContentBrowserClient::AllowWorkerIndexedDB( |
| 306 const GURL& url, | 306 const GURL& url, |
| 307 const string16& name, | 307 const base::string16& name, |
| 308 content::ResourceContext* context, | 308 content::ResourceContext* context, |
| 309 const std::vector<std::pair<int, int> >& render_frames) { | 309 const std::vector<std::pair<int, int> >& render_frames) { |
| 310 // Android WebView does not yet support web workers. | 310 // Android WebView does not yet support web workers. |
| 311 return false; | 311 return false; |
| 312 } | 312 } |
| 313 | 313 |
| 314 content::QuotaPermissionContext* | 314 content::QuotaPermissionContext* |
| 315 AwContentBrowserClient::CreateQuotaPermissionContext() { | 315 AwContentBrowserClient::CreateQuotaPermissionContext() { |
| 316 return new AwQuotaPermissionContext; | 316 return new AwQuotaPermissionContext; |
| 317 } | 317 } |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 483 WebPreferences* web_prefs) { | 483 WebPreferences* web_prefs) { |
| 484 if (!preferences_populater_.get()) { | 484 if (!preferences_populater_.get()) { |
| 485 preferences_populater_ = make_scoped_ptr(native_factory_-> | 485 preferences_populater_ = make_scoped_ptr(native_factory_-> |
| 486 CreateWebPreferencesPopulater()); | 486 CreateWebPreferencesPopulater()); |
| 487 } | 487 } |
| 488 preferences_populater_->PopulateFor( | 488 preferences_populater_->PopulateFor( |
| 489 content::WebContents::FromRenderViewHost(rvh), web_prefs); | 489 content::WebContents::FromRenderViewHost(rvh), web_prefs); |
| 490 } | 490 } |
| 491 | 491 |
| 492 } // namespace android_webview | 492 } // namespace android_webview |
| OLD | NEW |