[Xfce4-commits] <xfce4-battery-plugin:master> Make sure bar colors work with all gtk themes

Florian Rivoal noreply at xfce.org
Sat Feb 26 15:14:02 CET 2011


Updating branch refs/heads/master
         to 686cf28fc98ac8596714b1dd9317c16de1b3f34e (commit)
       from 0b52f89a640780540658316f8dd427d1953f4a4e (commit)

commit 686cf28fc98ac8596714b1dd9317c16de1b3f34e
Author: Florian Rivoal <frivoal at xfce.org>
Date:   Sat Feb 26 22:47:56 2011 +0900

    Make sure bar colors work with all gtk themes
    
    Fixes Bug #7329.

 panel-plugin/battery.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/panel-plugin/battery.c b/panel-plugin/battery.c
index a4eebf7..9e51ad1 100644
--- a/panel-plugin/battery.c
+++ b/panel-plugin/battery.c
@@ -559,14 +559,17 @@ battmon.c:241: for each function it appears in.)
     else {
       if(charge <= battmon->options.critical_percentage) {
         gtk_widget_modify_bg(battmon->battstatus, GTK_STATE_PRELIGHT, &(battmon->colorC));
+        gtk_widget_modify_bg(battmon->battstatus, GTK_STATE_SELECTED, &(battmon->colorC));
       }
       else if(charge <= battmon->options.low_percentage) {
         gtk_widget_modify_bg(battmon->battstatus, GTK_STATE_PRELIGHT, &(battmon->colorL));
+        gtk_widget_modify_bg(battmon->battstatus, GTK_STATE_SELECTED, &(battmon->colorL));
         battmon->critical = FALSE;
       }
       else {
             battmon->low = battmon->critical = FALSE;
         gtk_widget_modify_bg(battmon->battstatus, GTK_STATE_PRELIGHT, &(battmon->colorH));
+        gtk_widget_modify_bg(battmon->battstatus, GTK_STATE_SELECTED, &(battmon->colorH));
       }
     }
 



More information about the Xfce4-commits mailing list