From b6efbf1286eee3ae0c7ba4cfcedf66b7f4160b90 Mon Sep 17 00:00:00 2001 From: Mike Massonnet Date: Mon, 28 May 2012 21:32:04 +0200 Subject: [PATCH] Bug 8915: Keep colorized values after orientation change --- panel-plugin/netload.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/panel-plugin/netload.c b/panel-plugin/netload.c index 02b35b1..035f549 100644 --- a/panel-plugin/netload.c +++ b/panel-plugin/netload.c @@ -353,6 +353,14 @@ static void monitor_set_orientation (XfcePanelPlugin *plugin, GtkOrientation ori gtk_misc_set_alignment(GTK_MISC(global->monitor->sent_label), 1.0f, 0.5f); } + if (global->monitor->options.show_values) + { + gtk_widget_modify_fg(global->monitor->rcv_label, GTK_STATE_NORMAL, + (global->monitor->options.colorize_values ? &global->monitor->options.color[IN] : NULL)); + gtk_widget_modify_fg(global->monitor->sent_label, GTK_STATE_NORMAL, + (global->monitor->options.colorize_values ? &global->monitor->options.color[OUT] : NULL)); + } + gtk_box_pack_start(GTK_BOX(global->monitor->box), GTK_WIDGET(global->monitor->label), TRUE, FALSE, BORDER / 2);