mirror of
https://codeberg.org/dnkl/foot.git
synced 2026-02-05 04:06:08 -05:00
selection: don't initiate a paste when we're already pasting
This commit is contained in:
parent
9ec4c3fd94
commit
1707db1678
1 changed files with 10 additions and 0 deletions
10
selection.c
10
selection.c
|
|
@ -1204,6 +1204,11 @@ from_clipboard_done(void *user)
|
||||||
void
|
void
|
||||||
selection_from_clipboard(struct seat *seat, struct terminal *term, uint32_t serial)
|
selection_from_clipboard(struct seat *seat, struct terminal *term, uint32_t serial)
|
||||||
{
|
{
|
||||||
|
if (term->is_sending_paste_data) {
|
||||||
|
/* We're already pasting... */
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
struct wl_clipboard *clipboard = &seat->clipboard;
|
struct wl_clipboard *clipboard = &seat->clipboard;
|
||||||
if (clipboard->data_offer == NULL)
|
if (clipboard->data_offer == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
@ -1317,6 +1322,11 @@ selection_from_primary(struct seat *seat, struct terminal *term)
|
||||||
if (term->wl->primary_selection_device_manager == NULL)
|
if (term->wl->primary_selection_device_manager == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if (term->is_sending_paste_data) {
|
||||||
|
/* We're already pasting... */
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
struct wl_clipboard *clipboard = &seat->clipboard;
|
struct wl_clipboard *clipboard = &seat->clipboard;
|
||||||
if (clipboard->data_offer == NULL)
|
if (clipboard->data_offer == NULL)
|
||||||
return;
|
return;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue