summaryrefslogtreecommitdiff
path: root/src/input.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/input.c')
-rw-r--r--src/input.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/input.c b/src/input.c
index 60f4624..a0523eb 100644
--- a/src/input.c
+++ b/src/input.c
@@ -323,6 +323,14 @@ get_more_input (char *prompt, char *preinput)
if (cur_len > 0) cur_len--;
update_input_window(s, prompt, str, cur_len);
}
+ else if (ch == INPUT_ABORT_KEY && modifier == INPUT_ABORT_MODIFIER)
+ {
+ /* User aborted. */
+ free (str);
+ XSetInputFocus (dpy, fwin, RevertToPointerRoot, CurrentTime);
+ XUnmapWindow (dpy, s->input_window);
+ return NULL;
+ }
else
{
if (cur_len + nbytes > allocated_len - 1)