slint
slint copied to clipboard
Windows: Use of popup menu created through raw Win32 API causes UI using Slint widgets to go "mute"
I've found a problem where creating a popup menu with old-fashioned raw Win32 APIs. Specifically after TrackPopupMenu
is called, the UI seems to go "mute" - while mute the UI seems to be functional, but never actually redraws.
I've attached a demonstration of this problem. In the attached program, there are two buttons:
- One updates a text field, incrementing it by one all of the time
- The other button presents a Win32 popup menu (created with raw Win32 APIs) to provide the option of incrementing by one, two or three
When the popup menu is uses, the text field fails to update. That said, we can tell that the UI is still "functional" because if you resize the window, the UI stops being mute and the text immediately updates. Furthermore if you hit the left bump button while the UI is mute, it seems to track them.
Furthermore, the normal UX button highlighting fails while the UI is mute.
Of course, everything about this report is only relevant on Windows. win32_popup_problem.zip