1
0
mirror of https://github.com/taigrr/wtf synced 2025-01-18 04:03:14 -08:00

Close #202. Keep focus on the selected widget when a modal is closed

This commit is contained in:
Chris Cummer 2018-06-13 15:46:58 -07:00
parent 154cb3ea4f
commit c8b22eb588

View File

@ -36,6 +36,10 @@ func (tracker *FocusTracker) Next() {
// None removes focus from the currently-focused widget. // None removes focus from the currently-focused widget.
func (tracker *FocusTracker) None() { func (tracker *FocusTracker) None() {
if tracker.focusState() == NonWidget {
return
}
tracker.blur(tracker.Idx) tracker.blur(tracker.Idx)
} }