mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-04-25 06:46:36 -04:00
selection: block non-paste data from being sent to client while pasting
While pasting data from the clipboard, block *all* other data from being sent to the client. This includes keyboard and mouse events, but also replies for VT queries. This is particularly important when bracketed paste has been enabled, since then the client will interpret *everything* between the bracketed paste start and end as paste data.
This commit is contained in:
parent
81222dac57
commit
e570146c07
3 changed files with 133 additions and 53 deletions
|
|
@ -205,6 +205,8 @@ enum term_surface {
|
|||
TERM_SURF_BUTTON_CLOSE,
|
||||
};
|
||||
|
||||
typedef tll(struct ptmx_buffer) ptmx_buffer_list_t;
|
||||
|
||||
struct terminal {
|
||||
struct fdm *fdm;
|
||||
struct reaper *reaper;
|
||||
|
|
@ -226,7 +228,9 @@ struct terminal {
|
|||
float font_dpi;
|
||||
enum fcft_subpixel font_subpixel;
|
||||
|
||||
tll(struct ptmx_buffer) ptmx_buffer;
|
||||
bool is_sending_paste_data;
|
||||
ptmx_buffer_list_t ptmx_buffers;
|
||||
ptmx_buffer_list_t ptmx_paste_buffers;
|
||||
|
||||
enum cursor_origin origin;
|
||||
enum cursor_keys cursor_keys_mode;
|
||||
|
|
@ -489,6 +493,8 @@ int term_destroy(struct terminal *term);
|
|||
|
||||
void term_reset(struct terminal *term, bool hard);
|
||||
bool term_to_slave(struct terminal *term, const void *data, size_t len);
|
||||
bool term_paste_data_to_slave(
|
||||
struct terminal *term, const void *data, size_t len);
|
||||
|
||||
bool term_font_size_increase(struct terminal *term);
|
||||
bool term_font_size_decrease(struct terminal *term);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue