summaryrefslogtreecommitdiffstats
path: root/chrome/browser/gtk
diff options
context:
space:
mode:
authorestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-05 19:32:57 +0000
committerestade@chromium.org <estade@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-05-05 19:32:57 +0000
commit2584f41e80ac96ccd58293acd9187169054e8bee (patch)
tree9f12a6aa3d92296e5c85dc011864383f4bdaa800 /chrome/browser/gtk
parent0ed0e507e31f6fe59bc05a7fec767d6ee898767f (diff)
downloadchromium_src-2584f41e80ac96ccd58293acd9187169054e8bee.zip
chromium_src-2584f41e80ac96ccd58293acd9187169054e8bee.tar.gz
chromium_src-2584f41e80ac96ccd58293acd9187169054e8bee.tar.bz2
Set infobar text to black (overriding system default color).
Since we set the background color, we can't go letting the theme choose the text color unless we want to potentially end up with white on yellow. Review URL: http://codereview.chromium.org/108034 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@15320 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/gtk')
-rw-r--r--chrome/browser/gtk/infobar_gtk.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/chrome/browser/gtk/infobar_gtk.cc b/chrome/browser/gtk/infobar_gtk.cc
index 4430135..fcee318 100644
--- a/chrome/browser/gtk/infobar_gtk.cc
+++ b/chrome/browser/gtk/infobar_gtk.cc
@@ -125,6 +125,7 @@ class AlertInfoBar : public InfoBar {
: InfoBar(delegate) {
std::wstring text = delegate->GetMessageText();
GtkWidget* label = gtk_label_new(WideToUTF8(text).c_str());
+ gtk_widget_modify_fg(label, GTK_STATE_NORMAL, &gfx::kGdkBlack);
gtk_box_pack_start(GTK_BOX(hbox_), label, FALSE, FALSE, 0);
}
};
@@ -150,6 +151,7 @@ class LinkInfoBar : public InfoBar {
if (link_offset == std::wstring::npos) {
gtk_box_pack_end(GTK_BOX(hbox_), link_button_->widget(), FALSE, FALSE, 0);
GtkWidget* label = gtk_label_new(WideToUTF8(display_text).c_str());
+ gtk_widget_modify_fg(label, GTK_STATE_NORMAL, &gfx::kGdkBlack);
gtk_box_pack_start(GTK_BOX(hbox_), label, FALSE, FALSE, 0);
} else {
GtkWidget* initial_label = gtk_label_new(
@@ -157,6 +159,9 @@ class LinkInfoBar : public InfoBar {
GtkWidget* trailing_label = gtk_label_new(
WideToUTF8(display_text.substr(link_offset)).c_str());
+ gtk_widget_modify_fg(initial_label, GTK_STATE_NORMAL, &gfx::kGdkBlack);
+ gtk_widget_modify_fg(trailing_label, GTK_STATE_NORMAL, &gfx::kGdkBlack);
+
// We don't want any spacing between the elements, so we pack them into
// this hbox that doesn't use kElementPadding.
GtkWidget* hbox = gtk_hbox_new(FALSE, 0);