Skip to content

How to use List -> FocusLost() #3580

Answered by Jacalz
junmaqiang asked this question in Q&A
Discussion options

You must be logged in to vote

You should not call the FocusLost() method as that is what the focus manager calls to tell the widget that it has lost focus.

What you want to do is to make the list's .OnSelected(id ListItemID) function (https://pkg.go.dev/fyne.io/fyne/v2/widget#List) call .Unselect(id) (https://pkg.go.dev/fyne.io/fyne/v2/widget#List.Unselect) on the list.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by Jacalz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants