[Xfce4-commits] [panel-plugins/xfce4-whiskermenu-plugin] 252/473: Use a single row in Xfce 4.10 panel. Closes #39.

noreply at xfce.org noreply at xfce.org
Mon Feb 16 23:57:02 CET 2015


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

gottcode pushed a commit to branch master
in repository panel-plugins/xfce4-whiskermenu-plugin.

commit 5948856da67bc1a28b94dde2f57c4136a0154d80
Author: Graeme Gott <graeme at gottcode.org>
Date:   Wed Nov 20 09:41:03 2013 -0500

    Use a single row in Xfce 4.10 panel. Closes #39.
---
 panel-plugin/plugin.cpp |   12 +++++++++++-
 1 file changed, 11 insertions(+), 1 deletion(-)

diff --git a/panel-plugin/plugin.cpp b/panel-plugin/plugin.cpp
index 37e95b4..5f29700 100644
--- a/panel-plugin/plugin.cpp
+++ b/panel-plugin/plugin.cpp
@@ -340,6 +340,10 @@ bool Plugin::size_changed(int size)
 
 	if (!wm_settings->button_title_visible)
 	{
+#if (LIBXFCE4PANEL_CHECK_VERSION(4,9,0))
+		xfce_panel_plugin_set_small(m_plugin, true);
+#endif
+
 		xfce_panel_image_set_size(m_button_icon, -1);
 		if (orientation == GTK_ORIENTATION_HORIZONTAL)
 		{
@@ -358,9 +362,11 @@ bool Plugin::size_changed(int size)
 		gtk_widget_set_size_request(GTK_WIDGET(m_plugin), -1, -1);
 
 #if (LIBXFCE4PANEL_CHECK_VERSION(4,9,0))
-		// Put title next to icon if panel is wide enough
 		if (mode == XFCE_PANEL_PLUGIN_MODE_DESKBAR)
 		{
+			xfce_panel_plugin_set_small(m_plugin, false);
+
+			// Put title next to icon if panel is wide enough
 			GtkRequisition label_size;
 			gtk_widget_size_request(GTK_WIDGET(m_button_label), &label_size);
 			if (label_size.width <= (size - row_size))
@@ -368,6 +374,10 @@ bool Plugin::size_changed(int size)
 				orientation = GTK_ORIENTATION_HORIZONTAL;
 			}
 		}
+		else
+		{
+			xfce_panel_plugin_set_small(m_plugin, true);
+		}
 #endif
 	}
 

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


More information about the Xfce4-commits mailing list