From 30c8e845be91bcd3e903ec44f17ad686a7c285a7 Mon Sep 17 00:00:00 2001 From: Alexander Volkov Date: Tue, 5 May 2015 12:27:51 +0300 Subject: [PATCH] xcb: Use the correct property type when requesting virtual roots Virtual roots are windows, so we should request XCB_ATOM_WINDOW instead of XCB_ATOM_ATOM. Change-Id: I59558b1a3c37cb9bcad42bc0695d420f59088eb9 Reviewed-by: Uli Schlachter Reviewed-by: Lars Knoll --- src/plugins/platforms/xcb/qxcbwmsupport.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/plugins/platforms/xcb/qxcbwmsupport.cpp b/src/plugins/platforms/xcb/qxcbwmsupport.cpp index 7d31ac71184..82c1c1de776 100644 --- a/src/plugins/platforms/xcb/qxcbwmsupport.cpp +++ b/src/plugins/platforms/xcb/qxcbwmsupport.cpp @@ -94,14 +94,14 @@ void QXcbWMSupport::updateVirtualRoots() int offset = 0; int remaining = 0; do { - xcb_get_property_cookie_t cookie = xcb_get_property(xcb_connection(), false, root, atom(QXcbAtom::_NET_VIRTUAL_ROOTS), XCB_ATOM_ATOM, offset, 1024); + xcb_get_property_cookie_t cookie = xcb_get_property(xcb_connection(), false, root, atom(QXcbAtom::_NET_VIRTUAL_ROOTS), XCB_ATOM_WINDOW, offset, 1024); xcb_get_property_reply_t *reply = xcb_get_property_reply(xcb_connection(), cookie, NULL); if (!reply) break; remaining = 0; - if (reply->type == XCB_ATOM_ATOM && reply->format == 32) { + if (reply->type == XCB_ATOM_WINDOW && reply->format == 32) { int len = xcb_get_property_value_length(reply)/sizeof(xcb_window_t); xcb_window_t *roots = (xcb_window_t *)xcb_get_property_value(reply); int s = net_virtual_roots.size();