diff options
author | lukefromdc <[email protected]> | 2017-07-11 15:19:07 -0400 |
---|---|---|
committer | raveit65 <[email protected]> | 2017-07-18 07:40:16 +0200 |
commit | 735849425569b80477963fae7f4184cd41cf96c7 (patch) | |
tree | 9e69b4da63b98f45e2fe9c7cbb70f629c2c53592 /libmate-panel-applet | |
parent | 188c705473849e9432c48a0a1a58adb7423ec630 (diff) | |
download | mate-panel-735849425569b80477963fae7f4184cd41cf96c7.tar.bz2 mate-panel-735849425569b80477963fae7f4184cd41cf96c7.tar.xz |
fix applet crashes on transparent user-set panel bg
Avoid cairo function that seemed to be causing crashes related to setting geometry, use code copied from panel-background.c instead
Diffstat (limited to 'libmate-panel-applet')
-rw-r--r-- | libmate-panel-applet/mate-panel-applet.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libmate-panel-applet/mate-panel-applet.c b/libmate-panel-applet/mate-panel-applet.c index 5efde6b3..e726dfb4 100644 --- a/libmate-panel-applet/mate-panel-applet.c +++ b/libmate-panel-applet/mate-panel-applet.c @@ -1350,8 +1350,10 @@ mate_panel_applet_get_pattern_from_pixmap (MatePanelApplet *applet, width = gdk_window_get_width(window); height = gdk_window_get_height(window); - surface = cairo_image_surface_create (CAIRO_FORMAT_ARGB32, width, height); - + surface = gdk_window_create_similar_surface (window, + CAIRO_CONTENT_COLOR_ALPHA, + width, + height); gdk_error_trap_push (); cr = cairo_create (surface); cairo_set_source_surface (cr, background, -x, -y); |