rect.width = item_width;
rect.height = item_height;
- item->surface = display_create_surface(display, NULL, &rect, 0);
+ item->surface =
+ display_create_surface(display, NULL, &rect, SURFACE_SHM);
item->x = x;
item->y = y;
rectangle.width = item_width + 2 * pointer->width;
rectangle.height = item_height + 2 * pointer->height;
- surface = display_create_surface(dnd->display, NULL, &rectangle, 0);
+ surface = display_create_surface(dnd->display, NULL, &rectangle,
+ SURFACE_SHM);
cr = cairo_create(surface);
cairo_translate(cr, pointer->width, pointer->height);
if (check_size(rectangle) < 0)
return NULL;
#ifdef HAVE_CAIRO_EGL
- if (display->dpy)
+ if (display->dpy && !(flags & SURFACE_SHM))
return display_create_egl_window_surface(display,
surface,
flags,
#endif
#define SURFACE_OPAQUE 0x01
+#define SURFACE_SHM 0x02
cairo_surface_t *
display_create_surface(struct display *display,