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

Unified Diff: chrome/browser/ui/website_settings/website_settings_ui.cc

Issue 2702923002: Page Info: Hide default permissions with a value of Ask if the default is Ask. (Closed)
Patch Set: Fix #ifdef to allow testing MacViews. Created 3 years, 10 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
« no previous file with comments | « chrome/browser/ui/website_settings/website_settings_ui.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/website_settings/website_settings_ui.cc
diff --git a/chrome/browser/ui/website_settings/website_settings_ui.cc b/chrome/browser/ui/website_settings/website_settings_ui.cc
index 926d87dd1beb43a10a06ef892c6766f8ac4e3883..f1b8b4dd27a97111a67f865a85acc125a74f728a 100644
--- a/chrome/browser/ui/website_settings/website_settings_ui.cc
+++ b/chrome/browser/ui/website_settings/website_settings_ui.cc
@@ -284,6 +284,21 @@ base::string16 WebsiteSettingsUI::PermissionActionToUIString(
}
// static
+base::string16 WebsiteSettingsUI::GetPermissionButtonString(
+ VisiblePermissions visible_permissions) {
+ switch (visible_permissions) {
+ case VISIBLE_PERMISSIONS_NONE:
+ return l10n_util::GetStringUTF16(IDS_PAGE_INFO_EDIT_PERMISSIONS_LINK);
+ case VISIBLE_PERMISSIONS_SOME_BUT_NOT_ALL:
+ return l10n_util::GetStringUTF16(IDS_PAGE_INFO_SHOW_ALL_PERMISSIONS_LINK);
+ case VISIBLE_PERMISSIONS_ALL:
+ return l10n_util::GetStringUTF16(IDS_PAGE_INFO_SITE_SETTINGS_LINK);
+ default:
+ NOTREACHED();
+ }
+}
+
+// static
int WebsiteSettingsUI::GetPermissionIconID(ContentSettingsType type,
ContentSetting setting) {
bool use_blocked = (setting == CONTENT_SETTING_BLOCK);
« no previous file with comments | « chrome/browser/ui/website_settings/website_settings_ui.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698