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

Unified Diff: components/url_formatter/elide_url.h

Issue 1959933002: Add FormatOriginForSecurityDisplay which takes a const url::Origin& origin (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: address brettw@'s comments Created 4 years, 7 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 | « no previous file | components/url_formatter/elide_url.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/url_formatter/elide_url.h
diff --git a/components/url_formatter/elide_url.h b/components/url_formatter/elide_url.h
index 5f929cab3e9b9098d6bf231efee7a015c74f6506..acdccbf70e0adf5d293dbf2ba8f2d3ea587feb95 100644
--- a/components/url_formatter/elide_url.h
+++ b/components/url_formatter/elide_url.h
@@ -18,6 +18,10 @@ namespace gfx {
class FontList;
}
+namespace url {
+class Origin;
+}
+
namespace url_formatter {
// ElideUrl and Elide host require
@@ -78,6 +82,12 @@ base::string16 FormatUrlForSecurityDisplay(
const GURL& origin,
const SchemeDisplay scheme_display = SchemeDisplay::SHOW);
+// This is a convenience function for formatting a url::Origin in a concise and
+// human-friendly way, to help users make security-related decisions.
+base::string16 FormatOriginForSecurityDisplay(
+ const url::Origin& origin,
+ const SchemeDisplay scheme_display = SchemeDisplay::SHOW);
+
} // namespace url_formatter
#endif // COMPONENTS_URL_FORMATTER_ELIDE_URL_H_
« no previous file with comments | « no previous file | components/url_formatter/elide_url.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698