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

Unified Diff: chrome/browser/ui/libgtkui/native_theme_gtk2.cc

Issue 2623753002: Native themes: Add separator color (Closed)
Patch Set: Created 3 years, 11 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/libgtkui/native_theme_gtk2.cc
diff --git a/chrome/browser/ui/libgtkui/native_theme_gtk2.cc b/chrome/browser/ui/libgtkui/native_theme_gtk2.cc
index 13314f34d520a4e5d07a39822e692b188f808975..d1aa13b488de79447fc23937806ec000ca8eb8d7 100644
--- a/chrome/browser/ui/libgtkui/native_theme_gtk2.cc
+++ b/chrome/browser/ui/libgtkui/native_theme_gtk2.cc
@@ -197,6 +197,10 @@ SkColor NativeThemeGtk2::GetSystemColor(ColorId color_id) const {
case kColorId_LinkPressed:
return SK_ColorRED;
+ // Separator
+ case kColorId_SeparatorColor:
+ return GetFgColor(GetSeparator(), INSENSITIVE);
+
// Button
case kColorId_ButtonEnabledColor:
return GetTextColor(GetButton(), NORMAL);
@@ -455,4 +459,13 @@ GtkWidget* NativeThemeGtk2::GetMenuItem() const {
return fake_menu_item;
}
+GtkWidget* NativeThemeGtk2::GetSeparator() const {
+ static GtkWidget* fake_separator = NULL;
+
+ if (!fake_separator)
+ fake_separator = gtk_hseparator_new();
+
+ return fake_separator;
+}
+
} // namespace libgtkui

Powered by Google App Engine
This is Rietveld 408576698