[Xfce4-commits] [panel-plugins/xfce4-whiskermenu-plugin] 03/07: Fix sidebar wider than iconless categories.
noreply at xfce.org
noreply at xfce.org
Tue Oct 2 00:06:37 CEST 2018
This is an automated email from the git hooks/post-receive script.
g o t t c o d e p u s h e d a c o m m i t t o b r a n c h m a s t e r
in repository panel-plugins/xfce4-whiskermenu-plugin.
commit 4ff9e0e269cabc1d9ead5b1e531538d1477ed9e7
Author: Graeme Gott <graeme at gottcode.org>
Date: Sat Sep 29 05:19:51 2018 -0400
Fix sidebar wider than iconless categories.
---
panel-plugin/window.cpp | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/panel-plugin/window.cpp b/panel-plugin/window.cpp
index d4f0b0e..d7fe6c8 100644
--- a/panel-plugin/window.cpp
+++ b/panel-plugin/window.cpp
@@ -483,13 +483,6 @@ void WhiskerMenu::Window::show(const Position position)
g_object_ref(m_commands_box);
if (m_layout_commands_alternate)
{
- if (!m_sidebar_size_group)
- {
- m_sidebar_size_group = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
- gtk_size_group_add_widget(m_sidebar_size_group, GTK_WIDGET(m_sidebar));
- gtk_size_group_add_widget(m_sidebar_size_group, GTK_WIDGET(m_commands_box));
- }
-
gtk_container_remove(GTK_CONTAINER(m_title_box), GTK_WIDGET(m_commands_box));
gtk_box_pack_start(m_search_box, GTK_WIDGET(m_commands_box), false, false, 0);
}
@@ -509,6 +502,23 @@ void WhiskerMenu::Window::show(const Position position)
g_object_unref(m_commands_box);
}
+ if (m_layout_commands_alternate)
+ {
+ if (!m_sidebar_size_group && wm_settings->category_show_name)
+ {
+ m_sidebar_size_group = gtk_size_group_new(GTK_SIZE_GROUP_HORIZONTAL);
+ gtk_size_group_add_widget(m_sidebar_size_group, GTK_WIDGET(m_sidebar));
+ gtk_size_group_add_widget(m_sidebar_size_group, GTK_WIDGET(m_commands_box));
+ }
+ else if (m_sidebar_size_group && !wm_settings->category_show_name)
+ {
+ gtk_size_group_remove_widget(m_sidebar_size_group, GTK_WIDGET(m_sidebar));
+ gtk_size_group_remove_widget(m_sidebar_size_group, GTK_WIDGET(m_commands_box));
+ g_object_unref(m_sidebar_size_group);
+ m_sidebar_size_group = NULL;
+ }
+ }
+
if ((layout_left && !wm_settings->position_categories_alternate)
|| (!layout_left && wm_settings->position_categories_alternate))
{
--
To stop receiving notification emails like this one, please contact
the administrator of this repository.
More information about the Xfce4-commits
mailing list