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

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

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
Index: chrome/browser/ui/website_settings/website_settings_ui.h
diff --git a/chrome/browser/ui/website_settings/website_settings_ui.h b/chrome/browser/ui/website_settings/website_settings_ui.h
index a656ae571f47f267956fad5aafb91825919fcdc4..980c1571d7b26199fe68664841f6392d8e71c70d 100644
--- a/chrome/browser/ui/website_settings/website_settings_ui.h
+++ b/chrome/browser/ui/website_settings/website_settings_ui.h
@@ -43,6 +43,14 @@ class WebsiteSettingsUI {
NUM_TAB_IDS,
};
+ // A value that represents a what subset of permissions are shown. This is
+ // used to determine the behaviour of the permission button.
+ enum VisiblePermissions {
+ VISIBLE_PERMISSIONS_NONE,
+ VISIBLE_PERMISSIONS_SOME_BUT_NOT_ALL,
+ VISIBLE_PERMISSIONS_ALL,
+ };
+
// The security summary is styled depending on the security state. At the
// moment, the only styling we apply is color, but it could also include e.g.
// bolding.
@@ -155,6 +163,10 @@ class WebsiteSettingsUI {
ContentSetting default_setting,
content_settings::SettingSource source);
+ // Returns the UI string for the given permission |type|.
+ static base::string16 GetPermissionButtonString(
+ VisiblePermissions visible_permissions);
+
// Returns the icon resource ID for the given permission |type| and |setting|.
static int GetPermissionIconID(ContentSettingsType type,
ContentSetting setting);
@@ -194,6 +206,10 @@ class WebsiteSettingsUI {
const PermissionInfoList& permission_info_list,
ChosenObjectInfoList chosen_object_info_list) = 0;
+ // Sets permission button
+ virtual void UpdatePermissionButton(
+ VisiblePermissions visible_permissions) = 0;
+
// Sets site identity information.
virtual void SetIdentityInfo(const IdentityInfo& identity_info) = 0;
};
« no previous file with comments | « chrome/browser/ui/website_settings/website_settings.cc ('k') | chrome/browser/ui/website_settings/website_settings_ui.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698