| 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 495 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 506 | 506 |
| 507 #if defined(ENABLE_EXTENSIONS) | 507 #if defined(ENABLE_EXTENSIONS) |
| 508 // The extension activity contains details of which websites extensions | 508 // The extension activity contains details of which websites extensions |
| 509 // were active on. It therefore indirectly stores details of websites a | 509 // were active on. It therefore indirectly stores details of websites a |
| 510 // user has visited so best clean from here as well. | 510 // user has visited so best clean from here as well. |
| 511 extensions::ActivityLog::GetInstance(profile_)->RemoveURLs( | 511 extensions::ActivityLog::GetInstance(profile_)->RemoveURLs( |
| 512 std::set<GURL>()); | 512 std::set<GURL>()); |
| 513 #endif | 513 #endif |
| 514 } | 514 } |
| 515 | 515 |
| 516 ntp_snippets::ContentSuggestionsService* content_suggestions_service = |
| 517 ContentSuggestionsServiceFactory::GetForProfile(profile_); |
| 518 if (content_suggestions_service) { |
| 519 content_suggestions_service->ClearHistory(delete_begin_, delete_end_, |
| 520 filter); |
| 521 } |
| 522 |
| 516 #if defined(ENABLE_EXTENSIONS) | 523 #if defined(ENABLE_EXTENSIONS) |
| 517 // Clear launch times as they are a form of history. | 524 // Clear launch times as they are a form of history. |
| 518 extensions::ExtensionPrefs* extension_prefs = | 525 extensions::ExtensionPrefs* extension_prefs = |
| 519 extensions::ExtensionPrefs::Get(profile_); | 526 extensions::ExtensionPrefs::Get(profile_); |
| 520 extension_prefs->ClearLastLaunchTimes(); | 527 extension_prefs->ClearLastLaunchTimes(); |
| 521 #endif | 528 #endif |
| 522 | 529 |
| 523 // The power consumption history by origin contains details of websites | 530 // The power consumption history by origin contains details of websites |
| 524 // that were visited. | 531 // that were visited. |
| 525 power::OriginPowerMap* origin_power_map = | 532 power::OriginPowerMap* origin_power_map = |
| (...skipping 966 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1492 waiting_for_clear_offline_page_data_ = false; | 1499 waiting_for_clear_offline_page_data_ = false; |
| 1493 NotifyIfDone(); | 1500 NotifyIfDone(); |
| 1494 } | 1501 } |
| 1495 #endif | 1502 #endif |
| 1496 | 1503 |
| 1497 void BrowsingDataRemover::OnClearedDomainReliabilityMonitor() { | 1504 void BrowsingDataRemover::OnClearedDomainReliabilityMonitor() { |
| 1498 DCHECK_CURRENTLY_ON(BrowserThread::UI); | 1505 DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| 1499 waiting_for_clear_domain_reliability_monitor_ = false; | 1506 waiting_for_clear_domain_reliability_monitor_ = false; |
| 1500 NotifyIfDone(); | 1507 NotifyIfDone(); |
| 1501 } | 1508 } |
| OLD | NEW |