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

Unified Diff: ui/views/style/typography.cc

Issue 2918003002: Remove text_ prefixes from the views::style::Get* helper args. (Closed)
Patch Set: rebase Created 3 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 | « ui/views/style/typography.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/style/typography.cc
diff --git a/ui/views/style/typography.cc b/ui/views/style/typography.cc
index a9ad8ac6cf845ebebad36b1d5283eaefb4a66d8e..3bac1f27a81c63e96e89faf7b4536736a7fa407c 100644
--- a/ui/views/style/typography.cc
+++ b/ui/views/style/typography.cc
@@ -13,33 +13,30 @@ namespace views {
namespace style {
namespace {
-void ValidateContextAndStyle(int text_context, int text_style) {
- DCHECK_GE(text_context, VIEWS_TEXT_CONTEXT_START);
- DCHECK_LT(text_context, TEXT_CONTEXT_MAX);
- DCHECK_GE(text_style, VIEWS_TEXT_STYLE_START);
+void ValidateContextAndStyle(int context, int style) {
+ DCHECK_GE(context, VIEWS_TEXT_CONTEXT_START);
+ DCHECK_LT(context, TEXT_CONTEXT_MAX);
+ DCHECK_GE(style, VIEWS_TEXT_STYLE_START);
}
} // namespace
-const gfx::FontList& GetFont(int text_context, int text_style) {
- ValidateContextAndStyle(text_context, text_style);
- return LayoutProvider::Get()->GetTypographyProvider().GetFont(text_context,
- text_style);
+const gfx::FontList& GetFont(int context, int style) {
+ ValidateContextAndStyle(context, style);
+ return LayoutProvider::Get()->GetTypographyProvider().GetFont(context, style);
}
-SkColor GetColor(int text_context,
- int text_style,
- const ui::NativeTheme* theme) {
- ValidateContextAndStyle(text_context, text_style);
+SkColor GetColor(int context, int style, const ui::NativeTheme* theme) {
+ ValidateContextAndStyle(context, style);
DCHECK(theme);
- return LayoutProvider::Get()->GetTypographyProvider().GetColor(
- text_context, text_style, *theme);
+ return LayoutProvider::Get()->GetTypographyProvider().GetColor(context, style,
+ *theme);
}
-int GetLineHeight(int text_context, int text_style) {
- ValidateContextAndStyle(text_context, text_style);
- return LayoutProvider::Get()->GetTypographyProvider().GetLineHeight(
- text_context, text_style);
+int GetLineHeight(int context, int style) {
+ ValidateContextAndStyle(context, style);
+ return LayoutProvider::Get()->GetTypographyProvider().GetLineHeight(context,
+ style);
}
} // namespace style
« no previous file with comments | « ui/views/style/typography.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698