From 9db9a0d22515f90a75ec09deb900308e7604ad5a Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Sat, 16 Jan 2021 15:39:44 +0100 Subject: config: add ‘none’ as a possible value for ‘selection-target’ MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit When ‘selection-target’ is set to ‘none’, selecting text does not copy the text to _any_ clipboard. This patch also refactors the value parsing to be data driven. --- selection.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'selection.c') diff --git a/selection.c b/selection.c index fd1b1661..2b209ae2 100644 --- a/selection.c +++ b/selection.c @@ -657,6 +657,9 @@ selection_finalize(struct seat *seat, struct terminal *term, uint32_t serial) assert(term->selection.start.row <= term->selection.end.row); switch (term->conf->selection_target) { + case SELECTION_TARGET_NONE: + break; + case SELECTION_TARGET_PRIMARY: selection_to_primary(seat, term, serial); break; -- cgit v1.3