[Xfce4-commits] [apps/xfce4-mixer] 01/01: Fixed button sizing in some themes.

noreply at xfce.org noreply at xfce.org
Wed Apr 9 21:30:01 CEST 2014


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

andrzejr pushed a commit to branch master
in repository apps/xfce4-mixer.

commit fe42d581169fa9936670cca440e6dbf75d21ec2a
Author: Andrzej <ndrwrdck at gmail.com>
Date:   Wed Apr 9 20:29:48 2014 +0100

    Fixed button sizing in some themes.
---
 panel-plugin/xfce-mixer-plugin.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/panel-plugin/xfce-mixer-plugin.c b/panel-plugin/xfce-mixer-plugin.c
index 5562e80..949e63e 100644
--- a/panel-plugin/xfce-mixer-plugin.c
+++ b/panel-plugin/xfce-mixer-plugin.c
@@ -608,6 +608,7 @@ xfce_mixer_plugin_size_changed (XfcePanelPlugin *plugin,
                                 gint             size)
 {
   XfceMixerPlugin *mixer_plugin = XFCE_MIXER_PLUGIN (plugin);
+  gint             icon_size;
 
   g_return_val_if_fail (mixer_plugin != NULL, FALSE);
 
@@ -615,11 +616,12 @@ xfce_mixer_plugin_size_changed (XfcePanelPlugin *plugin,
   size /= xfce_panel_plugin_get_nrows (XFCE_PANEL_PLUGIN (mixer_plugin));
 
   /* Determine size for the volume button icons */
-  size -= 2 + 2 * MAX (mixer_plugin->button->style->xthickness, mixer_plugin->button->style->ythickness);
+  icon_size = size - 2 - 2 * MAX (mixer_plugin->button->style->xthickness, mixer_plugin->button->style->ythickness);
 
   /* Set volume button icon size and update the volume button */
-  xfce_volume_button_set_icon_size (XFCE_VOLUME_BUTTON (mixer_plugin->button), size);
+  xfce_volume_button_set_icon_size (XFCE_VOLUME_BUTTON (mixer_plugin->button), icon_size);
   xfce_volume_button_update (XFCE_VOLUME_BUTTON (mixer_plugin->button));
+  gtk_widget_set_size_request (mixer_plugin->button, size, size);
 
   return TRUE;
 }

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


More information about the Xfce4-commits mailing list