summaryrefslogtreecommitdiff
path: root/mate-panel/panel-menu-button.c
diff options
context:
space:
mode:
authorStefano Karapetsas <[email protected]>2012-05-13 19:09:31 +0200
committerStefano Karapetsas <[email protected]>2012-05-13 19:09:31 +0200
commit656540dac716816bbc906b373d6ff6e488e536bd (patch)
treea18a807d6d41283dfc82d3513e8518624335f3fa /mate-panel/panel-menu-button.c
parent69769af51fe3f072bfd2612a27afc095eb67384f (diff)
downloadmate-panel-656540dac716816bbc906b373d6ff6e488e536bd.tar.bz2
mate-panel-656540dac716816bbc906b373d6ff6e488e536bd.tar.xz
add option to hide arrow in menu button
https://github.com/mate-desktop/mate-panel/issues/24 https://bugzilla.gnome.org/show_bug.cgi?id=598196 patch by Damir Gilyazov
Diffstat (limited to 'mate-panel/panel-menu-button.c')
-rw-r--r--mate-panel/panel-menu-button.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/mate-panel/panel-menu-button.c b/mate-panel/panel-menu-button.c
index 6a08291a..091c3993 100644
--- a/mate-panel/panel-menu-button.c
+++ b/mate-panel/panel-menu-button.c
@@ -636,6 +636,7 @@ panel_menu_button_load (const char *menu_path,
gboolean locked,
int position,
gboolean exactpos,
+ gboolean has_arrow,
const char *id)
{
PanelMenuButton *button;
@@ -649,7 +650,7 @@ panel_menu_button_load (const char *menu_path,
"tooltip", tooltip,
"use-menu-path", use_menu_path,
"use-custom-icon", use_custom_icon,
- "has-arrow", TRUE,
+ "has-arrow", has_arrow,
NULL);
info = mate_panel_applet_register (GTK_WIDGET (button), NULL, NULL,
@@ -878,6 +879,7 @@ panel_menu_button_load_from_mateconf (PanelWidget *panel,
char *tooltip;
gboolean use_menu_path;
gboolean use_custom_icon;
+ gboolean has_arrow;
client = panel_mateconf_get_client ();
@@ -896,6 +898,9 @@ panel_menu_button_load_from_mateconf (PanelWidget *panel,
key = panel_mateconf_full_key (PANEL_MATECONF_OBJECTS, id, "use_custom_icon");
use_custom_icon = mateconf_client_get_bool (client, key, NULL);
+ key = panel_mateconf_full_key (PANEL_MATECONF_OBJECTS, id, "has_arrow");
+ has_arrow = mateconf_client_get_bool (client, key, NULL);
+
panel_menu_button_load (menu_path,
use_menu_path,
custom_icon,
@@ -905,6 +910,7 @@ panel_menu_button_load_from_mateconf (PanelWidget *panel,
locked,
position,
exactpos,
+ has_arrow,
id);
g_free (menu_path);