diff options
author | Victor Kareh <[email protected]> | 2019-11-28 07:00:29 -0500 |
---|---|---|
committer | monsta <[email protected]> | 2020-01-16 16:15:40 +0300 |
commit | 611f0b6abf6cf830318e934edb9deff4e2639cac (patch) | |
tree | a16be08107e7ac963ca51b04b84e48f020f3bfa8 /applets | |
parent | ce77bd40414743daadc0fe3b610d2d3810244314 (diff) | |
download | mate-panel-611f0b6abf6cf830318e934edb9deff4e2639cac.tar.bz2 mate-panel-611f0b6abf6cf830318e934edb9deff4e2639cac.tar.xz |
status-notifier: Render menu items as cairo surface
Diffstat (limited to 'applets')
-rw-r--r-- | applets/notification_area/status-notifier/sn-dbus-menu-item.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/applets/notification_area/status-notifier/sn-dbus-menu-item.c b/applets/notification_area/status-notifier/sn-dbus-menu-item.c index 2fe587cf..6ed8d2f5 100644 --- a/applets/notification_area/status-notifier/sn-dbus-menu-item.c +++ b/applets/notification_area/status-notifier/sn-dbus-menu-item.c @@ -197,7 +197,10 @@ sn_dbus_menu_item_new (GVariant *props) } else if (item->icon_data) { - image = gtk_image_new_from_pixbuf (item->icon_data); + cairo_surface_t *surface; + surface = gdk_cairo_surface_create_from_pixbuf (item->icon_data, 0, NULL); + image = gtk_image_new_from_surface (surface); + cairo_surface_destroy (surface); } item->item = gtk_image_menu_item_new (); @@ -334,7 +337,10 @@ sn_dbus_menu_item_update_props (SnDBusMenuItem *item, if (item->icon_data) { - image = gtk_image_new_from_pixbuf (item->icon_data); + cairo_surface_t *surface; + surface = gdk_cairo_surface_create_from_pixbuf (item->icon_data, 0, NULL); + image = gtk_image_new_from_surface (surface); + cairo_surface_destroy (surface); } else { |