mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-11-22 12:55:58 +01:00
selection fixes
This commit is contained in:
parent
52cda5653b
commit
a4bb0574c4
1 changed files with 6 additions and 4 deletions
|
@ -434,7 +434,8 @@ static int xwm_handle_xfixes_selection_notify(struct wlr_xwm *xwm,
|
|||
if (xwm->selection_owner != xwm->selection_window) {
|
||||
// A real X client selection went away, not our
|
||||
// proxy selection
|
||||
// TODO: Clear the wayland selection (or not)?
|
||||
wlr_seat_set_selection(xwm->seat, NULL,
|
||||
wl_display_next_serial(xwm->xwayland->wl_display));
|
||||
}
|
||||
|
||||
xwm->selection_owner = XCB_WINDOW_NONE;
|
||||
|
@ -442,6 +443,8 @@ static int xwm_handle_xfixes_selection_notify(struct wlr_xwm *xwm,
|
|||
return 1;
|
||||
}
|
||||
|
||||
xwm->selection_owner = xfixes_selection_notify->owner;
|
||||
|
||||
// We have to use XCB_TIME_CURRENT_TIME when we claim the
|
||||
// selection, so grab the actual timestamp here so we can
|
||||
// answer TIMESTAMP conversion requests correctly.
|
||||
|
@ -451,8 +454,6 @@ static int xwm_handle_xfixes_selection_notify(struct wlr_xwm *xwm,
|
|||
return 1;
|
||||
}
|
||||
|
||||
xwm->selection_owner = xfixes_selection_notify->owner;
|
||||
|
||||
xwm->incr = 0;
|
||||
// doing this will give a selection notify where we actually handle the sync
|
||||
xcb_convert_selection(xwm->xcb_conn, xwm->selection_window,
|
||||
|
@ -542,8 +543,9 @@ static void handle_seat_set_selection(struct wl_listener *listener,
|
|||
return;
|
||||
}
|
||||
|
||||
if (source->send == data_source_send)
|
||||
if (source->send == data_source_send) {
|
||||
return;
|
||||
}
|
||||
|
||||
xcb_set_selection_owner(xwm->xcb_conn,
|
||||
xwm->selection_window,
|
||||
|
|
Loading…
Reference in a new issue