Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(49)

Side by Side Diff: chrome/browser/browsing_data/browsing_data_remover.cc

Issue 2479593006: Move enable extensions define to a build flag. (Closed)
Patch Set: Merge Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #include <utility> 10 #include <utility>
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 #include "components/search_engines/template_url_service.h" 72 #include "components/search_engines/template_url_service.h"
73 #include "components/sessions/core/tab_restore_service.h" 73 #include "components/sessions/core/tab_restore_service.h"
74 #include "components/web_cache/browser/web_cache_manager.h" 74 #include "components/web_cache/browser/web_cache_manager.h"
75 #include "content/public/browser/browser_thread.h" 75 #include "content/public/browser/browser_thread.h"
76 #include "content/public/browser/download_manager.h" 76 #include "content/public/browser/download_manager.h"
77 #include "content/public/browser/notification_service.h" 77 #include "content/public/browser/notification_service.h"
78 #include "content/public/browser/plugin_data_remover.h" 78 #include "content/public/browser/plugin_data_remover.h"
79 #include "content/public/browser/ssl_host_state_delegate.h" 79 #include "content/public/browser/ssl_host_state_delegate.h"
80 #include "content/public/browser/storage_partition.h" 80 #include "content/public/browser/storage_partition.h"
81 #include "content/public/browser/user_metrics.h" 81 #include "content/public/browser/user_metrics.h"
82 #include "extensions/features/features.h"
82 #include "net/base/net_errors.h" 83 #include "net/base/net_errors.h"
83 #include "net/cookies/cookie_store.h" 84 #include "net/cookies/cookie_store.h"
84 #include "net/http/http_network_session.h" 85 #include "net/http/http_network_session.h"
85 #include "net/http/http_transaction_factory.h" 86 #include "net/http/http_transaction_factory.h"
86 #include "net/http/transport_security_state.h" 87 #include "net/http/transport_security_state.h"
87 #include "net/ssl/channel_id_service.h" 88 #include "net/ssl/channel_id_service.h"
88 #include "net/ssl/channel_id_store.h" 89 #include "net/ssl/channel_id_store.h"
89 #include "net/url_request/url_request_context.h" 90 #include "net/url_request/url_request_context.h"
90 #include "net/url_request/url_request_context_getter.h" 91 #include "net/url_request/url_request_context_getter.h"
91 #include "storage/browser/quota/special_storage_policy.h" 92 #include "storage/browser/quota/special_storage_policy.h"
92 #include "url/origin.h" 93 #include "url/origin.h"
93 94
94 #if BUILDFLAG(ANDROID_JAVA_UI) 95 #if BUILDFLAG(ANDROID_JAVA_UI)
95 #include "chrome/browser/android/offline_pages/offline_page_model_factory.h" 96 #include "chrome/browser/android/offline_pages/offline_page_model_factory.h"
96 #include "chrome/browser/android/webapps/webapp_registry.h" 97 #include "chrome/browser/android/webapps/webapp_registry.h"
97 #include "chrome/browser/precache/precache_manager_factory.h" 98 #include "chrome/browser/precache/precache_manager_factory.h"
98 #include "components/offline_pages/offline_page_feature.h" 99 #include "components/offline_pages/offline_page_feature.h"
99 #include "components/offline_pages/offline_page_model.h" 100 #include "components/offline_pages/offline_page_model.h"
100 #include "components/precache/content/precache_manager.h" 101 #include "components/precache/content/precache_manager.h"
101 #endif 102 #endif
102 103
103 #if defined(ENABLE_EXTENSIONS) 104 #if BUILDFLAG(ENABLE_EXTENSIONS)
104 #include "chrome/browser/extensions/activity_log/activity_log.h" 105 #include "chrome/browser/extensions/activity_log/activity_log.h"
105 #include "extensions/browser/extension_prefs.h" 106 #include "extensions/browser/extension_prefs.h"
106 #endif 107 #endif
107 108
108 #if defined(ENABLE_PLUGINS) 109 #if defined(ENABLE_PLUGINS)
109 #include "chrome/browser/browsing_data/browsing_data_flash_lso_helper.h" 110 #include "chrome/browser/browsing_data/browsing_data_flash_lso_helper.h"
110 #endif 111 #endif
111 112
112 #if BUILDFLAG(ENABLE_SESSION_SERVICE) 113 #if BUILDFLAG(ENABLE_SESSION_SERVICE)
113 #include "chrome/browser/sessions/session_service.h" 114 #include "chrome/browser/sessions/session_service.h"
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
527 &history_task_tracker_); 528 &history_task_tracker_);
528 } 529 }
529 530
530 ntp_snippets::ContentSuggestionsService* content_suggestions_service = 531 ntp_snippets::ContentSuggestionsService* content_suggestions_service =
531 ContentSuggestionsServiceFactory::GetForProfileIfExists(profile_); 532 ContentSuggestionsServiceFactory::GetForProfileIfExists(profile_);
532 if (content_suggestions_service) { 533 if (content_suggestions_service) {
533 content_suggestions_service->ClearHistory(delete_begin_, delete_end_, 534 content_suggestions_service->ClearHistory(delete_begin_, delete_end_,
534 filter); 535 filter);
535 } 536 }
536 537
537 #if defined(ENABLE_EXTENSIONS) 538 #if BUILDFLAG(ENABLE_EXTENSIONS)
538 // The extension activity log contains details of which websites extensions 539 // The extension activity log contains details of which websites extensions
539 // were active on. It therefore indirectly stores details of websites a 540 // were active on. It therefore indirectly stores details of websites a
540 // user has visited so best clean from here as well. 541 // user has visited so best clean from here as well.
541 // TODO(msramek): Support all backends with filter (crbug.com/589586). 542 // TODO(msramek): Support all backends with filter (crbug.com/589586).
542 extensions::ActivityLog::GetInstance(profile_)->RemoveURLs( 543 extensions::ActivityLog::GetInstance(profile_)->RemoveURLs(
543 std::set<GURL>()); 544 std::set<GURL>());
544 545
545 // Clear launch times as they are a form of history. 546 // Clear launch times as they are a form of history.
546 // BrowsingDataFilterBuilder currently doesn't support extension origins. 547 // BrowsingDataFilterBuilder currently doesn't support extension origins.
547 // Therefore, clearing history for a small set of origins (WHITELIST) should 548 // Therefore, clearing history for a small set of origins (WHITELIST) should
(...skipping 997 matching lines...) Expand 10 before | Expand all | Expand 10 after
1545 waiting_for_clear_offline_page_data_ = false; 1546 waiting_for_clear_offline_page_data_ = false;
1546 NotifyIfDone(); 1547 NotifyIfDone();
1547 } 1548 }
1548 #endif 1549 #endif
1549 1550
1550 void BrowsingDataRemover::OnClearedDomainReliabilityMonitor() { 1551 void BrowsingDataRemover::OnClearedDomainReliabilityMonitor() {
1551 DCHECK_CURRENTLY_ON(BrowserThread::UI); 1552 DCHECK_CURRENTLY_ON(BrowserThread::UI);
1552 waiting_for_clear_domain_reliability_monitor_ = false; 1553 waiting_for_clear_domain_reliability_monitor_ = false;
1553 NotifyIfDone(); 1554 NotifyIfDone();
1554 } 1555 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698