Chromium Code Reviews| 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/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 2724 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2735 void ChromeContentBrowserClient::ClearCache(RenderFrameHost* rfh) { | 2735 void ChromeContentBrowserClient::ClearCache(RenderFrameHost* rfh) { |
| 2736 Profile* profile = Profile::FromBrowserContext( | 2736 Profile* profile = Profile::FromBrowserContext( |
| 2737 rfh->GetSiteInstance()->GetProcess()->GetBrowserContext()); | 2737 rfh->GetSiteInstance()->GetProcess()->GetBrowserContext()); |
| 2738 BrowsingDataRemover* remover = | 2738 BrowsingDataRemover* remover = |
| 2739 BrowsingDataRemoverFactory::GetForBrowserContext(profile); | 2739 BrowsingDataRemoverFactory::GetForBrowserContext(profile); |
| 2740 remover->Remove(base::Time(), base::Time::Max(), | 2740 remover->Remove(base::Time(), base::Time::Max(), |
| 2741 BrowsingDataRemover::DATA_TYPE_CACHE, | 2741 BrowsingDataRemover::DATA_TYPE_CACHE, |
| 2742 BrowsingDataRemover::ORIGIN_TYPE_UNPROTECTED_WEB); | 2742 BrowsingDataRemover::ORIGIN_TYPE_UNPROTECTED_WEB); |
| 2743 } | 2743 } |
| 2744 | 2744 |
| 2745 void ChromeContentBrowserClient::ClearCookies(RenderFrameHost* rfh) { | |
| 2746 Profile* profile = Profile::FromBrowserContext( | |
| 2747 rfh->GetSiteInstance()->GetProcess()->GetBrowserContext()); | |
| 2748 BrowsingDataRemover* remover = | |
| 2749 BrowsingDataRemoverFactory::GetForBrowserContext(profile); | |
| 2750 int remove_mask = ChromeBrowsingDataRemoverDelegate::DATA_TYPE_SITE_DATA; | |
|
dgozman
2017/03/31 22:57:55
This looks like more than cookies, doesn't it? Let
phulce
2017/03/31 23:54:32
Oh yeah forgot to mention this was clearly a bug t
| |
| 2751 remover->Remove(base::Time(), base::Time::Max(), remove_mask, | |
| 2752 BrowsingDataRemover::ORIGIN_TYPE_UNPROTECTED_WEB); | |
| 2753 } | |
| 2754 | |
| 2755 void ChromeContentBrowserClient::ClearSiteData( | 2745 void ChromeContentBrowserClient::ClearSiteData( |
| 2756 content::BrowserContext* browser_context, | 2746 content::BrowserContext* browser_context, |
| 2757 const url::Origin& origin, | 2747 const url::Origin& origin, |
| 2758 bool remove_cookies, | 2748 bool remove_cookies, |
| 2759 bool remove_storage, | 2749 bool remove_storage, |
| 2760 bool remove_cache, | 2750 bool remove_cache, |
| 2761 const base::Closure& callback) { | 2751 const base::Closure& callback) { |
| 2762 BrowsingDataRemover* remover = | 2752 BrowsingDataRemover* remover = |
| 2763 BrowsingDataRemoverFactory::GetForBrowserContext(browser_context); | 2753 BrowsingDataRemoverFactory::GetForBrowserContext(browser_context); |
| 2764 | 2754 |
| (...skipping 814 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3579 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { | 3569 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { |
| 3580 return variations::GetVariationParamValue( | 3570 return variations::GetVariationParamValue( |
| 3581 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; | 3571 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; |
| 3582 } | 3572 } |
| 3583 | 3573 |
| 3584 // static | 3574 // static |
| 3585 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( | 3575 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( |
| 3586 const storage::QuotaSettings* settings) { | 3576 const storage::QuotaSettings* settings) { |
| 3587 g_default_quota_settings = settings; | 3577 g_default_quota_settings = settings; |
| 3588 } | 3578 } |
| OLD | NEW |