From b15032d223115ad0f65a182804ba914bf0fcc51b Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Tue, 5 Nov 2019 08:49:32 +0100 Subject: selection: text_from_{clipboard,primary}: add 'done' callback This callback is *always* called, including when there has been an error. This is in preparation for making text_from_{clipboard,primary} asynchronous. --- selection.h | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'selection.h') diff --git a/selection.h b/selection.h index 7345766c..9ff40919 100644 --- a/selection.h +++ b/selection.h @@ -29,9 +29,10 @@ bool text_to_clipboard(struct terminal *term, char *text, uint32_t serial); void text_from_clipboard( struct terminal *term, uint32_t serial, void (*cb)(const char *data, size_t size, void *user), - void *user); + void (*done)(void *user), void *user); bool text_to_primary(struct terminal *term, char *text, uint32_t serial); void text_from_primary( - struct terminal *term, void (*cb)(const char *data, size_t size, void *user), - void *user); + struct terminal *term, + void (*cb)(const char *data, size_t size, void *user), + void (*dont)(void *user), void *user); -- cgit v1.3