From b4acc239cd5b4b54787531409de8a7d2dd18c75b Mon Sep 17 00:00:00 2001 From: Egon Elbre Date: Tue, 5 Jul 2022 23:20:50 +0300 Subject: [PATCH] widget: fix Enum with Return The input op started listening to Return, however the check was looking for Enter. Signed-off-by: Egon Elbre --- widget/enum.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/widget/enum.go b/widget/enum.go index c5ed1e70..655bf4e0 100644 --- a/widget/enum.go +++ b/widget/enum.go @@ -99,7 +99,7 @@ func (e *Enum) Layout(gtx layout.Context, k string, content layout.Widget) layou if !e.focused || ev.State != key.Release { break } - if ev.Name != key.NameEnter && ev.Name != key.NameSpace { + if ev.Name != key.NameReturn && ev.Name != key.NameSpace { break } if state.key != e.Value { -- 2.45.2