mirror of
https://github.com/hyprwm/wlroots-hyprland.git
synced 2024-11-09 15:05:58 +01:00
edb30a6828
This change tracks, for each wlr_seat_client, the most recent serial numbers which were sent to the client. When the client makes a selection request, wlroots now verifies that the serial number associated with the selection request was actually provided to that specific client. This ensures that the client that was most recently interacted with always has priority for its copy selection requests, and that no other clients can incorrectly use a larger serial value and "steal" the role of having the copy selection. Also, the code used to determine when a given selection is superseded by a newer request uses < instead of <= to allow clients to make multiple selection requests with the same serial number and have the last one hold. To limit memory use, a ring buffer is used to store runs of sequential serial numbers, and all serial numbers earlier than the start of the ring buffer are assumed to be valid. Faking very old serials is unlikely to be disruptive. Assuming all clients are correctly written, the only additional constraint which this patch should impose is that serial numbers are now bound to seats: clients may not receive a serial number from an input event on one seat and then use that to request copy-selection on another seat. |
||
---|---|---|
.. | ||
meson.build | ||
wlr_box.h | ||
wlr_buffer.h | ||
wlr_compositor.h | ||
wlr_cursor.h | ||
wlr_data_control_v1.h | ||
wlr_data_device.h | ||
wlr_export_dmabuf_v1.h | ||
wlr_foreign_toplevel_management_v1.h | ||
wlr_fullscreen_shell_v1.h | ||
wlr_gamma_control_v1.h | ||
wlr_gtk_primary_selection.h | ||
wlr_idle.h | ||
wlr_idle_inhibit_v1.h | ||
wlr_input_device.h | ||
wlr_input_inhibitor.h | ||
wlr_input_method_v2.h | ||
wlr_keyboard.h | ||
wlr_layer_shell_v1.h | ||
wlr_linux_dmabuf_v1.h | ||
wlr_list.h | ||
wlr_matrix.h | ||
wlr_output.h | ||
wlr_output_damage.h | ||
wlr_output_layout.h | ||
wlr_output_management_v1.h | ||
wlr_pointer.h | ||
wlr_pointer_constraints_v1.h | ||
wlr_pointer_gestures_v1.h | ||
wlr_presentation_time.h | ||
wlr_primary_selection.h | ||
wlr_primary_selection_v1.h | ||
wlr_region.h | ||
wlr_relative_pointer_v1.h | ||
wlr_screencopy_v1.h | ||
wlr_seat.h | ||
wlr_server_decoration.h | ||
wlr_surface.h | ||
wlr_switch.h | ||
wlr_tablet_pad.h | ||
wlr_tablet_tool.h | ||
wlr_tablet_v2.h | ||
wlr_text_input_v3.h | ||
wlr_touch.h | ||
wlr_virtual_keyboard_v1.h | ||
wlr_xcursor_manager.h | ||
wlr_xdg_decoration_v1.h | ||
wlr_xdg_output_v1.h | ||
wlr_xdg_shell.h | ||
wlr_xdg_shell_v6.h |