[Xfce4-commits] [panel-plugins/xfce4-sensors-plugin] 01/02: Repaired suppress-tooltips feature

noreply at xfce.org noreply at xfce.org
Mon Mar 20 23:53:17 CET 2017


This is an automated email from the git hooks/post-receive script.

timystery pushed a commit to branch master
in repository panel-plugins/xfce4-sensors-plugin.

commit ca93870d59a4b1a3cec38c77d4f74b6337a5147e
Author: Fabian <timystery at arcor.de>
Date:   Mon Mar 20 23:52:36 2017 +0100

    Repaired suppress-tooltips feature
---
 panel-plugin/sensors-plugin.c | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/panel-plugin/sensors-plugin.c b/panel-plugin/sensors-plugin.c
index ceebd00..217ef97 100644
--- a/panel-plugin/sensors-plugin.c
+++ b/panel-plugin/sensors-plugin.c
@@ -1080,7 +1080,8 @@ sensors_show_panel (gpointer data)
         gtk_widget_set_valign(sensors->panel_label_text, GTK_ALIGN_CENTER);
     }
 
-    sensors_create_tooltip ((gpointer) sensors);
+    if (!sensors->suppresstooltip)
+        sensors_create_tooltip ((gpointer) sensors);
 
     TRACE ("leaves sensors_show_panel\n");
     return result;
@@ -1389,6 +1390,9 @@ suppresstooltip_changed (GtkWidget *widget, t_sensors_dialog* sd)
 
     gtk_widget_set_has_tooltip(sd->sensors->eventbox, !sd->sensors->suppresstooltip);
 
+if (! sd->sensors->suppresstooltip)
+        sensors_create_tooltip ((gpointer) sd->sensors);
+
     TRACE ("leaves suppresstooltip_changed");
 }
 
@@ -2573,6 +2577,9 @@ sensors_plugin_construct (XfcePanelPlugin *plugin)
     ptr_sensorsstruct->plugin_config_file = xfce_panel_plugin_lookup_rc_file(plugin);
     sensors_read_config (plugin, ptr_sensorsstruct);
 
+    /* use values from config file */
+    gtk_widget_set_has_tooltip(ptr_sensorsstruct->eventbox, !ptr_sensorsstruct->suppresstooltip);
+
     if (ptr_sensorsstruct->cover_panel_rows || xfce_panel_plugin_get_mode(plugin) == XFCE_PANEL_PLUGIN_MODE_DESKBAR)
         xfce_panel_plugin_set_small(plugin, FALSE);
     else

-- 
To stop receiving notification emails like this one, please contact
the administrator of this repository.


More information about the Xfce4-commits mailing list