Merge branch 'xfixes' into next

Partially merge #6.

Close #6
This commit is contained in:
Yuxuan Shui 2018-09-29 17:08:39 +01:00
commit 70fb58bfbd
2 changed files with 8 additions and 2 deletions

View File

@ -9,7 +9,7 @@ MANDIR ?= $(PREFIX)/share/man/man1
APPDIR ?= $(PREFIX)/share/applications APPDIR ?= $(PREFIX)/share/applications
ICODIR ?= $(PREFIX)/share/icons/hicolor/ ICODIR ?= $(PREFIX)/share/icons/hicolor/
PACKAGES = x11 x11-xcb xcb-renderutil xcb-render xcb-damage xcb-randr xcb-image xcomposite xfixes xext PACKAGES = x11 x11-xcb xcb-renderutil xcb-render xcb-damage xcb-randr xcb-xfixes xfixes xcb-image xcomposite xext
LIBS = -lm -lrt LIBS = -lm -lrt
INCS = INCS =

View File

@ -5349,6 +5349,7 @@ session_init(session_t *ps_old, int argc, char **argv) {
xcb_prefetch_extension_data(c, &xcb_render_id); xcb_prefetch_extension_data(c, &xcb_render_id);
xcb_prefetch_extension_data(c, &xcb_damage_id); xcb_prefetch_extension_data(c, &xcb_damage_id);
xcb_prefetch_extension_data(c, &xcb_xfixes_id);
xcb_prefetch_extension_data(c, &xcb_randr_id); xcb_prefetch_extension_data(c, &xcb_randr_id);
ext_info = xcb_get_extension_data(c, &xcb_render_id); ext_info = xcb_get_extension_data(c, &xcb_render_id);
@ -5386,10 +5387,15 @@ session_init(session_t *ps_old, int argc, char **argv) {
xcb_discard_reply(c, xcb_discard_reply(c,
xcb_damage_query_version(c, XCB_DAMAGE_MAJOR_VERSION, XCB_DAMAGE_MINOR_VERSION).sequence); xcb_damage_query_version(c, XCB_DAMAGE_MAJOR_VERSION, XCB_DAMAGE_MINOR_VERSION).sequence);
if (!XFixesQueryExtension(ps->dpy, &ps->xfixes_event, &ps->xfixes_error)) { ext_info = xcb_get_extension_data(c, &xcb_xfixes_id);
if (!ext_info || !ext_info->present) {
fprintf(stderr, "No XFixes extension\n"); fprintf(stderr, "No XFixes extension\n");
exit(1); exit(1);
} }
ps->xfixes_event = ext_info->first_event;
ps->xfixes_error = ext_info->first_error;
xcb_discard_reply(c,
xcb_xfixes_query_version(c, XCB_XFIXES_MAJOR_VERSION, XCB_XFIXES_MINOR_VERSION).sequence);
// Build a safe representation of display name // Build a safe representation of display name
{ {