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 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
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_comp ression_stats.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_serv ice.h" |
55 #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" |
56 #include "components/domain_reliability/service.h" | 56 #include "components/domain_reliability/service.h" |
57 #include "components/history/core/browser/history_service.h" | 57 #include "components/history/core/browser/history_service.h" |
58 #include "components/nacl/browser/nacl_browser.h" | 58 #include "components/nacl/browser/nacl_browser.h" |
59 #include "components/nacl/browser/pnacl_host.h" | 59 #include "components/nacl/browser/pnacl_host.h" |
60 #include "components/ntp_snippets/bookmarks/bookmark_last_visit_utils.h" | 60 #include "components/ntp_snippets/bookmarks/bookmark_last_visit_utils.h" |
61 #include "components/ntp_snippets/content_suggestions_service.h" | 61 #include "components/ntp_snippets/content_suggestions_service.h" |
62 #include "components/omnibox/browser/omnibox_pref_names.h" | 62 #include "components/omnibox/browser/omnibox_pref_names.h" |
63 #include "components/open_from_clipboard/clipboard_recent_content.h" | |
63 #include "components/password_manager/core/browser/password_store.h" | 64 #include "components/password_manager/core/browser/password_store.h" |
64 #include "components/prefs/pref_service.h" | 65 #include "components/prefs/pref_service.h" |
65 #include "components/previews/core/previews_ui_service.h" | 66 #include "components/previews/core/previews_ui_service.h" |
66 #include "components/search_engines/template_url_service.h" | 67 #include "components/search_engines/template_url_service.h" |
67 #include "components/sessions/core/tab_restore_service.h" | 68 #include "components/sessions/core/tab_restore_service.h" |
68 #include "components/translate/core/browser/language_model.h" | 69 #include "components/translate/core/browser/language_model.h" |
69 #include "components/web_cache/browser/web_cache_manager.h" | 70 #include "components/web_cache/browser/web_cache_manager.h" |
70 #include "content/public/browser/browsing_data_filter_builder.h" | 71 #include "content/public/browser/browsing_data_filter_builder.h" |
71 #include "content/public/browser/plugin_data_remover.h" | 72 #include "content/public/browser/plugin_data_remover.h" |
72 #include "content/public/browser/ssl_host_state_delegate.h" | 73 #include "content/public/browser/ssl_host_state_delegate.h" |
(...skipping 339 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
412 profile_, ServiceAccessType::EXPLICIT_ACCESS); | 413 profile_, ServiceAccessType::EXPLICIT_ACCESS); |
413 if (history_service) { | 414 if (history_service) { |
414 // TODO(dmurph): Support all backends with filter (crbug.com/113621). | 415 // TODO(dmurph): Support all backends with filter (crbug.com/113621). |
415 base::RecordAction(UserMetricsAction("ClearBrowsingData_History")); | 416 base::RecordAction(UserMetricsAction("ClearBrowsingData_History")); |
416 clear_history_.Start(); | 417 clear_history_.Start(); |
417 history_service->ExpireLocalAndRemoteHistoryBetween( | 418 history_service->ExpireLocalAndRemoteHistoryBetween( |
418 WebHistoryServiceFactory::GetForProfile(profile_), std::set<GURL>(), | 419 WebHistoryServiceFactory::GetForProfile(profile_), std::set<GURL>(), |
419 delete_begin_, delete_end_, | 420 delete_begin_, delete_end_, |
420 clear_history_.GetCompletionCallback(), | 421 clear_history_.GetCompletionCallback(), |
421 &history_task_tracker_); | 422 &history_task_tracker_); |
423 // TODO(mpearson): do I want to / need to gate this on "not incognito" | |
424 // the way iOS does? Or does requiring history_service be valid already | |
425 // do that for me? | |
426 ClipboardRecentContent::GetInstance()->SuppressClipboardContent(); | |
Mark P
2017/04/01 05:21:04
For context, I'm trying to make a call analogous t
| |
422 } | 427 } |
423 | 428 |
424 // Currently, ContentSuggestionService instance exists only on Android. | 429 // Currently, ContentSuggestionService instance exists only on Android. |
425 ntp_snippets::ContentSuggestionsService* content_suggestions_service = | 430 ntp_snippets::ContentSuggestionsService* content_suggestions_service = |
426 ContentSuggestionsServiceFactory::GetForProfileIfExists(profile_); | 431 ContentSuggestionsServiceFactory::GetForProfileIfExists(profile_); |
427 if (content_suggestions_service) { | 432 if (content_suggestions_service) { |
428 content_suggestions_service->ClearHistory(delete_begin_, delete_end_, | 433 content_suggestions_service->ClearHistory(delete_begin_, delete_end_, |
429 filter); | 434 filter); |
430 } | 435 } |
431 | 436 |
(...skipping 690 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1122 } | 1127 } |
1123 | 1128 |
1124 void ChromeBrowsingDataRemoverDelegate:: | 1129 void ChromeBrowsingDataRemoverDelegate:: |
1125 OnDeauthorizeFlashContentLicensesCompleted( | 1130 OnDeauthorizeFlashContentLicensesCompleted( |
1126 uint32_t request_id, | 1131 uint32_t request_id, |
1127 bool /* success */) { | 1132 bool /* success */) { |
1128 DCHECK_EQ(request_id, deauthorize_flash_content_licenses_request_id_); | 1133 DCHECK_EQ(request_id, deauthorize_flash_content_licenses_request_id_); |
1129 clear_flash_content_licenses_.GetCompletionCallback().Run(); | 1134 clear_flash_content_licenses_.GetCompletionCallback().Run(); |
1130 } | 1135 } |
1131 #endif | 1136 #endif |
OLD | NEW |