From 7988deaf353b9364ef2eedfc086477ca47e0c7d3 Mon Sep 17 00:00:00 2001 From: Chuck Jungmann Date: Thu, 16 Mar 2023 11:41:59 -0500 Subject: [PATCH] Add response to ESCAPE key, as advertised in the documentation. --- form.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/form.c b/form.c index 24c601d..44fd552 100644 --- a/form.c +++ b/form.c @@ -669,6 +669,8 @@ static struct eventResult formEvent(newtComponent co, struct event ev) { er.result = ER_SWALLOWED; dir = -1; wrap = 1; + } else if (ev.u.key == NEWT_KEY_ESCAPE) { + er.result = ER_EXITFORM; } }