diff options
author | lukefromdc <[email protected]> | 2015-12-26 17:35:48 -0500 |
---|---|---|
committer | Wolfgang Ulbrich <[email protected]> | 2016-01-03 02:08:54 +0100 |
commit | 4dbb7347a4b344658d28cfd49f6a925f000422ee (patch) | |
tree | d8946823a7cff52455d62bcf5cfee43a19872834 /cpufreq | |
parent | 76198a103be40a7a955d1aac953548e6fea82ab5 (diff) | |
download | mate-applets-4dbb7347a4b344658d28cfd49f6a925f000422ee.tar.bz2 mate-applets-4dbb7347a4b344658d28cfd49f6a925f000422ee.tar.xz |
gtk3: stop cpufreq-applet turning transparent
gtk3: stop cpufreq-applet turning transparent -prevent the cpufreq applet and panel area beneath from becoming transparent to the desktop when a menu item in the popup menu is clicked. Veriied to work on gtk3.19.5
Diffstat (limited to 'cpufreq')
-rw-r--r-- | cpufreq/src/cpufreq-popup.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/cpufreq/src/cpufreq-popup.c b/cpufreq/src/cpufreq-popup.c index 82dc756a..278ebaf4 100644 --- a/cpufreq/src/cpufreq-popup.c +++ b/cpufreq/src/cpufreq-popup.c @@ -16,7 +16,7 @@ * License along with this library; if not, write to the Free * Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. * - * Authors : Carlos Garc�a Campos <[email protected]> + * Authors : Carlos García Campos <[email protected]> */ #include <glib/gi18n.h> @@ -198,8 +198,10 @@ cpufreq_popup_frequencies_menu_activate (GtkAction *action, cpu = cpufreq_monitor_get_cpu (popup->priv->monitor); name = gtk_action_get_name (action); freq = (guint) atoi (name + strlen ("Frequency")); + /*stop applet from turning transparent when menu clicked in gtk3.16 or later */ +#if !GTK_CHECK_VERSION (3, 0, 0) parent = GDK_WINDOW_XID (gtk_widget_get_window (popup->priv->parent)); - +#endif cpufreq_selector_set_frequency_async (selector, cpu, freq, parent); } @@ -222,8 +224,10 @@ cpufreq_popup_governors_menu_activate (GtkAction *action, cpu = cpufreq_monitor_get_cpu (popup->priv->monitor); name = gtk_action_get_name (action); governor = name + strlen ("Governor"); + /*stop applet from turning transparent when menu clicked in gtk3.16 or later */ +#if !GTK_CHECK_VERSION (3, 0, 0) parent = GDK_WINDOW_XID (gtk_widget_get_window (popup->priv->parent)); - +#endif cpufreq_selector_set_governor_async (selector, cpu, governor, parent); } |