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

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

Issue 2262223002: Material Page Info (all desktop): Introduce new strings and styling info for the security section. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move tests from followup CL into this one. Created 4 years, 3 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 71fe27b3c7b6dec0bfbaa7a4c15d90a800a5dd76..e776ff93aaa7aee9ad1882a09e615fca24f45272 100644
--- a/chrome/browser/ui/website_settings/website_settings_ui.h
+++ b/chrome/browser/ui/website_settings/website_settings_ui.h
@@ -48,6 +48,19 @@ class WebsiteSettingsUI {
NUM_TAB_IDS,
};
+ // 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.
+ enum SecuritySummaryStyle { STYLE_UNSTYLED = 0, STYLE_COLOR = 1 << 1 };
+
+ struct SecurityDescription {
+ // A one-line summary of the security state.
+ base::string16 summary;
+ // A short paragraph with more details about the state, and how
+ // the user should treat it.
+ base::string16 details;
+ };
+
// |CookieInfo| contains information about the cookies from a specific source.
// A source can for example be a specific origin or an entire wildcard domain.
struct CookieInfo {
@@ -103,7 +116,9 @@ class WebsiteSettingsUI {
std::string site_identity;
// Status of the site's identity.
WebsiteSettings::SiteIdentityStatus identity_status;
- // Helper to get the status text to display to the user.
+ // Helper to get security description info to display to the user.
+ std::unique_ptr<SecurityDescription> GetSecurityDescription() const;
+ // Deprecated method go get just the summary from GetSecurityDescription().
base::string16 GetSecuritySummary() const;
// Textual description of the site's identity status that is displayed to
// the user.

Powered by Google App Engine
This is Rietveld 408576698