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

Unified Diff: components/offline_pages/core/client_policy_controller.cc

Issue 2640923003: Remove popup overlay from MHTML when requested (Closed)
Patch Set: Created 3 years, 11 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 side-by-side diff with in-line comments
Download patch
Index: components/offline_pages/core/client_policy_controller.cc
diff --git a/components/offline_pages/core/client_policy_controller.cc b/components/offline_pages/core/client_policy_controller.cc
index c2db05186411b5d96974f87364d9400e21f298ce..aa9e4bf473d5dd9eecebb9ae91b3c4a70ac6e8ff 100644
--- a/components/offline_pages/core/client_policy_controller.cc
+++ b/components/offline_pages/core/client_policy_controller.cc
@@ -35,6 +35,7 @@ ClientPolicyController::ClientPolicyController() {
kUnlimitedPages, kUnlimitedPages)
.SetIsSupportedByDownload(true)
.SetIsRemovedOnCacheReset(false)
+ .SetRemovePopupOverlay(true)
.Build()));
policies_.insert(std::make_pair(
kCCTNamespace,
@@ -154,6 +155,11 @@ ClientPolicyController::GetNamespacesRestrictedToOriginalTab() const {
return *show_in_original_tab_cache_;
}
+bool ClientPolicyController::ShouldRemovePopupOverlay(
+ const std::string& name_space) const {
+ return GetPolicy(name_space).feature_policy.remove_popup_overlay;
+}
+
void ClientPolicyController::AddPolicyForTest(
const std::string& name_space,
const OfflinePageClientPolicyBuilder& builder) {

Powered by Google App Engine
This is Rietveld 408576698