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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2892953002: Remove the ClearCookies and ClearCache methods from ContentBrowserClient (Closed)
Patch Set: Merge conflict in BUILD.gn -> Rebase Created 3 years, 7 months 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/chrome_content_browser_client.h" 5 #include "chrome/browser/chrome_content_browser_client.h"
6 6
7 #include <map> 7 #include <map>
8 #include <set> 8 #include <set>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 2747 matching lines...) Expand 10 before | Expand all | Expand 10 after
2758 #else 2758 #else
2759 // Handler to rewrite chrome://newtab for InstantExtended. 2759 // Handler to rewrite chrome://newtab for InstantExtended.
2760 handler->AddHandlerPair(&search::HandleNewTabURLRewrite, 2760 handler->AddHandlerPair(&search::HandleNewTabURLRewrite,
2761 &search::HandleNewTabURLReverseRewrite); 2761 &search::HandleNewTabURLReverseRewrite);
2762 #endif 2762 #endif
2763 2763
2764 // chrome: & friends. 2764 // chrome: & friends.
2765 handler->AddHandlerPair(&HandleWebUI, &HandleWebUIReverse); 2765 handler->AddHandlerPair(&HandleWebUI, &HandleWebUIReverse);
2766 } 2766 }
2767 2767
2768 void ChromeContentBrowserClient::ClearCache(RenderFrameHost* rfh) {
2769 content::BrowsingDataRemover* remover =
2770 content::BrowserContext::GetBrowsingDataRemover(
2771 rfh->GetSiteInstance()->GetProcess()->GetBrowserContext());
2772 remover->Remove(base::Time(), base::Time::Max(),
2773 content::BrowsingDataRemover::DATA_TYPE_CACHE,
2774 content::BrowsingDataRemover::ORIGIN_TYPE_UNPROTECTED_WEB);
2775 }
2776
2777 void ChromeContentBrowserClient::ClearSiteData( 2768 void ChromeContentBrowserClient::ClearSiteData(
2778 content::BrowserContext* browser_context, 2769 content::BrowserContext* browser_context,
2779 const url::Origin& origin, 2770 const url::Origin& origin,
2780 bool remove_cookies, 2771 bool remove_cookies,
2781 bool remove_storage, 2772 bool remove_storage,
2782 bool remove_cache, 2773 bool remove_cache,
2783 const base::Closure& callback) { 2774 const base::Closure& callback) {
2784 content::BrowsingDataRemover* remover = 2775 content::BrowsingDataRemover* remover =
2785 content::BrowserContext::GetBrowsingDataRemover(browser_context); 2776 content::BrowserContext::GetBrowsingDataRemover(browser_context);
2786 2777
(...skipping 822 matching lines...) Expand 10 before | Expand all | Expand 10 after
3609 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { 3600 RedirectNonUINonIOBrowserThreadsToTaskScheduler() {
3610 return variations::GetVariationParamValue( 3601 return variations::GetVariationParamValue(
3611 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; 3602 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true";
3612 } 3603 }
3613 3604
3614 // static 3605 // static
3615 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( 3606 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting(
3616 const storage::QuotaSettings* settings) { 3607 const storage::QuotaSettings* settings) {
3617 g_default_quota_settings = settings; 3608 g_default_quota_settings = settings;
3618 } 3609 }
OLDNEW
« no previous file with comments | « chrome/browser/chrome_content_browser_client.h ('k') | content/browser/devtools/protocol/network_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698