mirror of
https://git.sr.ht/~eliasnaur/gio
synced 2026-07-05 09:25:38 +00:00
io/key: [API] introduce FocusFilter for matching focus and editor events
Signed-off-by: Elias Naur <mail@eliasnaur.com>
This commit is contained in:
+1
-1
@@ -162,7 +162,7 @@ func (b *Clickable) Update(gtx layout.Context) []Click {
|
||||
})
|
||||
}
|
||||
}
|
||||
for _, e := range gtx.Events(&b.keyTag) {
|
||||
for _, e := range gtx.Events(&b.keyTag, key.FocusFilter{}) {
|
||||
switch e := e.(type) {
|
||||
case key.FocusEvent:
|
||||
b.focused = e.Focus
|
||||
|
||||
Reference in New Issue
Block a user