| 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 "chrome/browser/browsing_data/browsing_data_remover.h" | 5 #include "chrome/browser/browsing_data/browsing_data_remover.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 #include "chrome/browser/io_thread.h" | 26 #include "chrome/browser/io_thread.h" |
| 27 #include "chrome/browser/media/media_device_id_salt.h" | 27 #include "chrome/browser/media/media_device_id_salt.h" |
| 28 #include "chrome/browser/net/predictor.h" | 28 #include "chrome/browser/net/predictor.h" |
| 29 #include "chrome/browser/password_manager/password_store_factory.h" | 29 #include "chrome/browser/password_manager/password_store_factory.h" |
| 30 #include "chrome/browser/predictors/logged_in_predictor_table.h" | 30 #include "chrome/browser/predictors/logged_in_predictor_table.h" |
| 31 #include "chrome/browser/predictors/predictor_database.h" | 31 #include "chrome/browser/predictors/predictor_database.h" |
| 32 #include "chrome/browser/predictors/predictor_database_factory.h" | 32 #include "chrome/browser/predictors/predictor_database_factory.h" |
| 33 #include "chrome/browser/prerender/prerender_manager.h" | 33 #include "chrome/browser/prerender/prerender_manager.h" |
| 34 #include "chrome/browser/prerender/prerender_manager_factory.h" | 34 #include "chrome/browser/prerender/prerender_manager_factory.h" |
| 35 #include "chrome/browser/profiles/profile.h" | 35 #include "chrome/browser/profiles/profile.h" |
| 36 #include "chrome/browser/renderer_host/web_cache_manager.h" | |
| 37 #include "chrome/browser/safe_browsing/safe_browsing_service.h" | 36 #include "chrome/browser/safe_browsing/safe_browsing_service.h" |
| 38 #include "chrome/browser/search_engines/template_url_service_factory.h" | 37 #include "chrome/browser/search_engines/template_url_service_factory.h" |
| 39 #include "chrome/browser/sessions/session_service.h" | 38 #include "chrome/browser/sessions/session_service.h" |
| 40 #include "chrome/browser/sessions/session_service_factory.h" | 39 #include "chrome/browser/sessions/session_service_factory.h" |
| 41 #include "chrome/browser/sessions/tab_restore_service.h" | 40 #include "chrome/browser/sessions/tab_restore_service.h" |
| 42 #include "chrome/browser/sessions/tab_restore_service_factory.h" | 41 #include "chrome/browser/sessions/tab_restore_service_factory.h" |
| 43 #include "chrome/browser/webdata/web_data_service_factory.h" | 42 #include "chrome/browser/webdata/web_data_service_factory.h" |
| 44 #include "chrome/common/pref_names.h" | 43 #include "chrome/common/pref_names.h" |
| 45 #include "chrome/common/url_constants.h" | 44 #include "chrome/common/url_constants.h" |
| 46 #include "components/autofill/core/browser/personal_data_manager.h" | 45 #include "components/autofill/core/browser/personal_data_manager.h" |
| 47 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" | 46 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" |
| 48 #include "components/domain_reliability/service.h" | 47 #include "components/domain_reliability/service.h" |
| 49 #include "components/nacl/browser/nacl_browser.h" | 48 #include "components/nacl/browser/nacl_browser.h" |
| 50 #include "components/nacl/browser/pnacl_host.h" | 49 #include "components/nacl/browser/pnacl_host.h" |
| 51 #include "components/password_manager/core/browser/password_store.h" | 50 #include "components/password_manager/core/browser/password_store.h" |
| 52 #include "components/search_engines/template_url_service.h" | 51 #include "components/search_engines/template_url_service.h" |
| 52 #include "components/web_cache/browser/web_cache_manager.h" |
| 53 #include "content/public/browser/browser_thread.h" | 53 #include "content/public/browser/browser_thread.h" |
| 54 #include "content/public/browser/dom_storage_context.h" | 54 #include "content/public/browser/dom_storage_context.h" |
| 55 #include "content/public/browser/download_manager.h" | 55 #include "content/public/browser/download_manager.h" |
| 56 #include "content/public/browser/local_storage_usage_info.h" | 56 #include "content/public/browser/local_storage_usage_info.h" |
| 57 #include "content/public/browser/notification_service.h" | 57 #include "content/public/browser/notification_service.h" |
| 58 #include "content/public/browser/plugin_data_remover.h" | 58 #include "content/public/browser/plugin_data_remover.h" |
| 59 #include "content/public/browser/session_storage_usage_info.h" | 59 #include "content/public/browser/session_storage_usage_info.h" |
| 60 #include "content/public/browser/ssl_host_state_delegate.h" | 60 #include "content/public/browser/ssl_host_state_delegate.h" |
| 61 #include "content/public/browser/storage_partition.h" | 61 #include "content/public/browser/storage_partition.h" |
| 62 #include "content/public/browser/user_metrics.h" | 62 #include "content/public/browser/user_metrics.h" |
| (...skipping 501 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 564 | 564 |
| 565 autofill::PersonalDataManager* data_manager = | 565 autofill::PersonalDataManager* data_manager = |
| 566 autofill::PersonalDataManagerFactory::GetForProfile(profile_); | 566 autofill::PersonalDataManagerFactory::GetForProfile(profile_); |
| 567 if (data_manager) | 567 if (data_manager) |
| 568 data_manager->Refresh(); | 568 data_manager->Refresh(); |
| 569 } | 569 } |
| 570 } | 570 } |
| 571 | 571 |
| 572 if (remove_mask & REMOVE_CACHE) { | 572 if (remove_mask & REMOVE_CACHE) { |
| 573 // Tell the renderers to clear their cache. | 573 // Tell the renderers to clear their cache. |
| 574 WebCacheManager::GetInstance()->ClearCache(); | 574 web_cache::WebCacheManager::GetInstance()->ClearCache(); |
| 575 | 575 |
| 576 // Invoke DoClearCache on the IO thread. | 576 // Invoke DoClearCache on the IO thread. |
| 577 waiting_for_clear_cache_ = true; | 577 waiting_for_clear_cache_ = true; |
| 578 content::RecordAction(UserMetricsAction("ClearBrowsingData_Cache")); | 578 content::RecordAction(UserMetricsAction("ClearBrowsingData_Cache")); |
| 579 | 579 |
| 580 BrowserThread::PostTask( | 580 BrowserThread::PostTask( |
| 581 BrowserThread::IO, FROM_HERE, | 581 BrowserThread::IO, FROM_HERE, |
| 582 base::Bind(&BrowsingDataRemover::ClearCacheOnIOThread, | 582 base::Bind(&BrowsingDataRemover::ClearCacheOnIOThread, |
| 583 base::Unretained(this))); | 583 base::Unretained(this))); |
| 584 | 584 |
| (...skipping 598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1183 waiting_for_clear_webrtc_logs_ = false; | 1183 waiting_for_clear_webrtc_logs_ = false; |
| 1184 NotifyAndDeleteIfDone(); | 1184 NotifyAndDeleteIfDone(); |
| 1185 } | 1185 } |
| 1186 #endif | 1186 #endif |
| 1187 | 1187 |
| 1188 void BrowsingDataRemover::OnClearedDomainReliabilityMonitor() { | 1188 void BrowsingDataRemover::OnClearedDomainReliabilityMonitor() { |
| 1189 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 1189 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 1190 waiting_for_clear_domain_reliability_monitor_ = false; | 1190 waiting_for_clear_domain_reliability_monitor_ = false; |
| 1191 NotifyAndDeleteIfDone(); | 1191 NotifyAndDeleteIfDone(); |
| 1192 } | 1192 } |
| OLD | NEW |