+#ifdef HAVE_QT5_X11_EXTRAS
+ // Refresh the selection request timestamp.
+ // We have to do this by ourselves as Qt seems
+ // not doing that, maybe because of our
+ // "persistent selection" implementation
+ // (see comments in GuiSelection.cpp).
+ xcb_selection_notify_event_t nev;
+ nev.response_type = XCB_SELECTION_NOTIFY;
+ nev.requestor = srev->requestor;
+ nev.selection = srev->selection;
+ nev.target = srev->target;
+ nev.property = XCB_NONE;
+ nev.time = XCB_CURRENT_TIME;
+ xcb_connection_t * con = QX11Info::connection();
+ xcb_send_event(con, 0, srev->requestor,
+ XCB_EVENT_MASK_NO_EVENT,
+ reinterpret_cast<char const *>(&nev));
+ xcb_flush(con);
+#endif
+ return true;
+ }