Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/chrome_browsing_data_remover_delegate.h" | 5 #include "chrome/browser/browsing_data/chrome_browsing_data_remover_delegate.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 21 matching lines...) Expand all Loading... | |
| 32 #include "chrome/browser/password_manager/password_store_factory.h" | 32 #include "chrome/browser/password_manager/password_store_factory.h" |
| 33 #include "chrome/browser/permissions/permission_decision_auto_blocker.h" | 33 #include "chrome/browser/permissions/permission_decision_auto_blocker.h" |
| 34 #include "chrome/browser/prerender/prerender_manager.h" | 34 #include "chrome/browser/prerender/prerender_manager.h" |
| 35 #include "chrome/browser/prerender/prerender_manager_factory.h" | 35 #include "chrome/browser/prerender/prerender_manager_factory.h" |
| 36 #include "chrome/browser/previews/previews_service.h" | 36 #include "chrome/browser/previews/previews_service.h" |
| 37 #include "chrome/browser/previews/previews_service_factory.h" | 37 #include "chrome/browser/previews/previews_service_factory.h" |
| 38 #include "chrome/browser/profiles/profile.h" | 38 #include "chrome/browser/profiles/profile.h" |
| 39 #include "chrome/browser/safe_browsing/safe_browsing_service.h" | 39 #include "chrome/browser/safe_browsing/safe_browsing_service.h" |
| 40 #include "chrome/browser/search_engines/template_url_service_factory.h" | 40 #include "chrome/browser/search_engines/template_url_service_factory.h" |
| 41 #include "chrome/browser/sessions/tab_restore_service_factory.h" | 41 #include "chrome/browser/sessions/tab_restore_service_factory.h" |
| 42 #include "chrome/browser/translate/language_model_factory.h" | |
| 42 #include "chrome/browser/web_data_service_factory.h" | 43 #include "chrome/browser/web_data_service_factory.h" |
| 43 #include "chrome/common/features.h" | 44 #include "chrome/common/features.h" |
| 44 #include "chrome/common/pref_names.h" | 45 #include "chrome/common/pref_names.h" |
| 45 #include "chrome/common/url_constants.h" | 46 #include "chrome/common/url_constants.h" |
| 46 #include "components/autofill/core/browser/personal_data_manager.h" | 47 #include "components/autofill/core/browser/personal_data_manager.h" |
| 47 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" | 48 #include "components/autofill/core/browser/webdata/autofill_webdata_service.h" |
| 48 #include "components/bookmarks/browser/bookmark_model.h" | 49 #include "components/bookmarks/browser/bookmark_model.h" |
| 49 #include "components/content_settings/core/browser/host_content_settings_map.h" | 50 #include "components/content_settings/core/browser/host_content_settings_map.h" |
| 50 #include "components/content_settings/core/common/content_settings.h" | 51 #include "components/content_settings/core/common/content_settings.h" |
| 51 #include "components/content_settings/core/common/content_settings_pattern.h" | 52 #include "components/content_settings/core/common/content_settings_pattern.h" |
| 52 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_comp ression_stats.h" | 53 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_comp ression_stats.h" |
| 53 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_serv ice.h" | 54 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_serv ice.h" |
| 54 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_sett ings.h" | 55 #include "components/data_reduction_proxy/core/browser/data_reduction_proxy_sett ings.h" |
| 55 #include "components/domain_reliability/service.h" | 56 #include "components/domain_reliability/service.h" |
| 56 #include "components/history/core/browser/history_service.h" | 57 #include "components/history/core/browser/history_service.h" |
| 57 #include "components/nacl/browser/nacl_browser.h" | 58 #include "components/nacl/browser/nacl_browser.h" |
| 58 #include "components/nacl/browser/pnacl_host.h" | 59 #include "components/nacl/browser/pnacl_host.h" |
| 59 #include "components/ntp_snippets/bookmarks/bookmark_last_visit_utils.h" | 60 #include "components/ntp_snippets/bookmarks/bookmark_last_visit_utils.h" |
| 60 #include "components/ntp_snippets/content_suggestions_service.h" | 61 #include "components/ntp_snippets/content_suggestions_service.h" |
| 61 #include "components/omnibox/browser/omnibox_pref_names.h" | 62 #include "components/omnibox/browser/omnibox_pref_names.h" |
| 62 #include "components/password_manager/core/browser/password_store.h" | 63 #include "components/password_manager/core/browser/password_store.h" |
| 63 #include "components/prefs/pref_service.h" | 64 #include "components/prefs/pref_service.h" |
| 64 #include "components/previews/core/previews_ui_service.h" | 65 #include "components/previews/core/previews_ui_service.h" |
| 65 #include "components/search_engines/template_url_service.h" | 66 #include "components/search_engines/template_url_service.h" |
| 66 #include "components/sessions/core/tab_restore_service.h" | 67 #include "components/sessions/core/tab_restore_service.h" |
| 68 #include "components/translate/core/browser/language_model.h" | |
| 67 #include "content/public/browser/plugin_data_remover.h" | 69 #include "content/public/browser/plugin_data_remover.h" |
| 68 #include "content/public/browser/ssl_host_state_delegate.h" | 70 #include "content/public/browser/ssl_host_state_delegate.h" |
| 69 #include "content/public/browser/storage_partition.h" | 71 #include "content/public/browser/storage_partition.h" |
| 70 #include "content/public/browser/user_metrics.h" | 72 #include "content/public/browser/user_metrics.h" |
| 71 #include "net/cookies/cookie_store.h" | 73 #include "net/cookies/cookie_store.h" |
| 72 #include "net/http/http_transaction_factory.h" | 74 #include "net/http/http_transaction_factory.h" |
| 73 #include "net/url_request/url_request_context.h" | 75 #include "net/url_request/url_request_context.h" |
| 74 #include "net/url_request/url_request_context_getter.h" | 76 #include "net/url_request/url_request_context_getter.h" |
| 75 | 77 |
| 76 #if defined(OS_ANDROID) | 78 #if defined(OS_ANDROID) |
| (...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 369 } | 371 } |
| 370 | 372 |
| 371 // Remove the last visit dates meta-data from the bookmark model. | 373 // Remove the last visit dates meta-data from the bookmark model. |
| 372 bookmarks::BookmarkModel* bookmark_model = | 374 bookmarks::BookmarkModel* bookmark_model = |
| 373 BookmarkModelFactory::GetForBrowserContext(profile_); | 375 BookmarkModelFactory::GetForBrowserContext(profile_); |
| 374 if (bookmark_model) { | 376 if (bookmark_model) { |
| 375 ntp_snippets::RemoveLastVisitedDatesBetween(delete_begin_, delete_end_, | 377 ntp_snippets::RemoveLastVisitedDatesBetween(delete_begin_, delete_end_, |
| 376 filter, bookmark_model); | 378 filter, bookmark_model); |
| 377 } | 379 } |
| 378 | 380 |
| 381 translate::LanguageModel* language_model = | |
| 382 LanguageModelFactory::GetInstance()->GetForBrowserContext(profile_); | |
|
msramek
2017/01/24 15:35:34
style: 4 spaces on continuation of the previous li
jkrcal
2017/01/25 08:48:54
Done.
| |
| 383 if (language_model) { | |
| 384 language_model->ClearHistory(delete_begin_, delete_end_); | |
| 385 } | |
| 386 | |
| 379 #if BUILDFLAG(ENABLE_EXTENSIONS) | 387 #if BUILDFLAG(ENABLE_EXTENSIONS) |
| 380 // The extension activity log contains details of which websites extensions | 388 // The extension activity log contains details of which websites extensions |
| 381 // were active on. It therefore indirectly stores details of websites a | 389 // were active on. It therefore indirectly stores details of websites a |
| 382 // user has visited so best clean from here as well. | 390 // user has visited so best clean from here as well. |
| 383 // TODO(msramek): Support all backends with filter (crbug.com/589586). | 391 // TODO(msramek): Support all backends with filter (crbug.com/589586). |
| 384 extensions::ActivityLog::GetInstance(profile_)->RemoveURLs( | 392 extensions::ActivityLog::GetInstance(profile_)->RemoveURLs( |
| 385 std::set<GURL>()); | 393 std::set<GURL>()); |
| 386 | 394 |
| 387 // Clear launch times as they are a form of history. | 395 // Clear launch times as they are a form of history. |
| 388 // BrowsingDataFilterBuilder currently doesn't support extension origins. | 396 // BrowsingDataFilterBuilder currently doesn't support extension origins. |
| (...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1041 } | 1049 } |
| 1042 | 1050 |
| 1043 void ChromeBrowsingDataRemoverDelegate:: | 1051 void ChromeBrowsingDataRemoverDelegate:: |
| 1044 OnDeauthorizeFlashContentLicensesCompleted( | 1052 OnDeauthorizeFlashContentLicensesCompleted( |
| 1045 uint32_t request_id, | 1053 uint32_t request_id, |
| 1046 bool /* success */) { | 1054 bool /* success */) { |
| 1047 DCHECK_EQ(request_id, deauthorize_flash_content_licenses_request_id_); | 1055 DCHECK_EQ(request_id, deauthorize_flash_content_licenses_request_id_); |
| 1048 clear_flash_content_licenses_.GetCompletionCallback().Run(); | 1056 clear_flash_content_licenses_.GetCompletionCallback().Run(); |
| 1049 } | 1057 } |
| 1050 #endif | 1058 #endif |
| OLD | NEW |