Chromium Code Reviews| 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_browser_context.h" | 5 #include "android_webview/browser/aw_browser_context.h" |
| 6 | 6 |
| 7 #include "android_webview/browser/aw_form_database_service.h" | 7 #include "android_webview/browser/aw_form_database_service.h" |
| 8 #include "android_webview/browser/aw_pref_store.h" | 8 #include "android_webview/browser/aw_pref_store.h" |
| 9 #include "android_webview/browser/aw_quota_manager_bridge.h" | 9 #include "android_webview/browser/aw_quota_manager_bridge.h" |
| 10 #include "android_webview/browser/aw_resource_context.h" | 10 #include "android_webview/browser/aw_resource_context.h" |
| (...skipping 329 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 340 // Intentionally returning NULL as 'Extensions' and 'Apps' not supported. | 340 // Intentionally returning NULL as 'Extensions' and 'Apps' not supported. |
| 341 return NULL; | 341 return NULL; |
| 342 } | 342 } |
| 343 | 343 |
| 344 content::PushMessagingService* AwBrowserContext::GetPushMessagingService() { | 344 content::PushMessagingService* AwBrowserContext::GetPushMessagingService() { |
| 345 // TODO(johnme): Support push messaging in WebView. | 345 // TODO(johnme): Support push messaging in WebView. |
| 346 return NULL; | 346 return NULL; |
| 347 } | 347 } |
| 348 | 348 |
| 349 content::SSLHostStateDelegate* AwBrowserContext::GetSSLHostStateDelegate() { | 349 content::SSLHostStateDelegate* AwBrowserContext::GetSSLHostStateDelegate() { |
| 350 return NULL; | 350 if (!ssl_host_state_delegate_.get()) { |
| 351 ssl_host_state_delegate_.reset(new AwSSLHostStateDelegate()); | |
| 352 } | |
| 353 | |
|
sgurun-gerrit only
2014/12/12 04:23:09
nit: remove empty line
hush (inactive)
2014/12/12 19:43:39
Done.
| |
| 354 return ssl_host_state_delegate_.get(); | |
| 351 } | 355 } |
| 352 | 356 |
| 353 void AwBrowserContext::RebuildTable( | 357 void AwBrowserContext::RebuildTable( |
| 354 const scoped_refptr<URLEnumerator>& enumerator) { | 358 const scoped_refptr<URLEnumerator>& enumerator) { |
| 355 // Android WebView rebuilds from WebChromeClient.getVisitedHistory. The client | 359 // Android WebView rebuilds from WebChromeClient.getVisitedHistory. The client |
| 356 // can change in the lifetime of this WebView and may not yet be set here. | 360 // can change in the lifetime of this WebView and may not yet be set here. |
| 357 // Therefore this initialization path is not used. | 361 // Therefore this initialization path is not used. |
| 358 enumerator->OnComplete(true); | 362 enumerator->OnComplete(true); |
| 359 } | 363 } |
| 360 | 364 |
| 361 void AwBrowserContext::CreateDataReductionProxyStatisticsIfNecessary() { | 365 void AwBrowserContext::CreateDataReductionProxyStatisticsIfNecessary() { |
| 362 DCHECK(user_pref_service_.get()); | 366 DCHECK(user_pref_service_.get()); |
| 363 | 367 |
| 364 if (!data_reduction_proxy_statistics_.get()) { | 368 if (!data_reduction_proxy_statistics_.get()) { |
| 365 // We don't care about commit_delay for now. It is just a dummy value. | 369 // We don't care about commit_delay for now. It is just a dummy value. |
| 366 base::TimeDelta commit_delay = base::TimeDelta::FromMinutes(60); | 370 base::TimeDelta commit_delay = base::TimeDelta::FromMinutes(60); |
| 367 data_reduction_proxy_statistics_ = | 371 data_reduction_proxy_statistics_ = |
| 368 scoped_ptr<data_reduction_proxy::DataReductionProxyStatisticsPrefs>( | 372 scoped_ptr<data_reduction_proxy::DataReductionProxyStatisticsPrefs>( |
| 369 new data_reduction_proxy::DataReductionProxyStatisticsPrefs( | 373 new data_reduction_proxy::DataReductionProxyStatisticsPrefs( |
| 370 user_pref_service_.get(), | 374 user_pref_service_.get(), |
| 371 base::MessageLoopProxy::current(), | 375 base::MessageLoopProxy::current(), |
| 372 commit_delay)); | 376 commit_delay)); |
| 373 } | 377 } |
| 374 } | 378 } |
| 375 | 379 |
| 376 } // namespace android_webview | 380 } // namespace android_webview |
| OLD | NEW |