Skip to content

Commit

Permalink
Support new mate-menus api
Browse files Browse the repository at this point in the history
  • Loading branch information
yetist authored and raveit65 committed May 30, 2018
1 parent 10b2021 commit 2631577
Show file tree
Hide file tree
Showing 7 changed files with 306 additions and 249 deletions.
2 changes: 1 addition & 1 deletion mate-panel/drawer-private.h
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ static void load_drawer_applet (char *toplevel_id,
const char *id);

static void panel_drawer_prepare (const char *drawer_id,
const char *custom_icon,
GIcon *custom_icon,
gboolean use_custom_icon,
const char *tooltip,
char **attached_toplevel_id);
Expand Down
11 changes: 7 additions & 4 deletions mate-panel/drawer.c
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ load_drawer_applet (char *toplevel_id,

static void
panel_drawer_prepare (const char *drawer_id,
const char *custom_icon,
GIcon *custom_icon,
gboolean use_custom_icon,
const char *tooltip,
char **attached_toplevel_id)
Expand All @@ -587,7 +587,10 @@ panel_drawer_prepare (const char *drawer_id,
g_settings_set_boolean (settings, PANEL_OBJECT_USE_CUSTOM_ICON_KEY, use_custom_icon);

if (custom_icon) {
g_settings_set_string (settings, PANEL_OBJECT_CUSTOM_ICON_KEY, custom_icon);
gchar *icon_name;
icon_name = g_icon_to_string(custom_icon);
g_settings_set_string (settings, PANEL_OBJECT_CUSTOM_ICON_KEY, icon_name);
g_free(icon_name);
}

if (attached_toplevel_id) {
Expand Down Expand Up @@ -618,7 +621,7 @@ panel_drawer_prepare (const char *drawer_id,
void
panel_drawer_create (PanelToplevel *toplevel,
int position,
const char *custom_icon,
GIcon *custom_icon,
gboolean use_custom_icon,
const char *tooltip)
{
Expand All @@ -636,7 +639,7 @@ panel_drawer_create (PanelToplevel *toplevel,
char *
panel_drawer_create_with_id (const char *toplevel_id,
int position,
const char *custom_icon,
GIcon *custom_icon,
gboolean use_custom_icon,
const char *tooltip)
{
Expand Down
4 changes: 2 additions & 2 deletions mate-panel/drawer.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,13 +25,13 @@ typedef struct {

void panel_drawer_create (PanelToplevel *toplevel,
int position,
const char *custom_icon,
GIcon *custom_icon,
gboolean use_custom_icon,
const char *tooltip);

char *panel_drawer_create_with_id (const char *toplevel_id,
int position,
const char *custom_icon,
GIcon *custom_icon,
gboolean use_custom_icon,
const char *tooltip);

Expand Down
Loading

0 comments on commit 2631577

Please sign in to comment.