Run colored select popup updates on main thread

This commit is contained in:
Stu Leak 2026-01-04 08:05:23 -05:00
parent f120aa0feb
commit f5d9edd4bc

View File

@ -1302,6 +1302,7 @@ func (cs *ColoredSelect) showPopup() {
} }
// Hide popup after a short delay to allow the selection to be processed // Hide popup after a short delay to allow the selection to be processed
time.AfterFunc(50*time.Millisecond, func() { time.AfterFunc(50*time.Millisecond, func() {
fyne.CurrentApp().Driver().RunOnMain(func() {
if cs.popup != nil { if cs.popup != nil {
cs.popup.Hide() cs.popup.Hide()
cs.popup = nil cs.popup = nil
@ -1309,6 +1310,7 @@ func (cs *ColoredSelect) showPopup() {
} }
}) })
}) })
})
items[i] = tappableItem items[i] = tappableItem
} }