This looks like it's consistent with the normal menus. And it fixes the issue where multiple menus can be shown at once because it would hide slower than show the next one.
Contributes to issue CURA-8640.
Getting a bit complex with the timers there and which pop-ups need to stay open. But it seems to be working reliably now.
Contributes to issue CURA-8640.
The sub-menus were giving segfaults for some reason. We couldn't figure out how to circumvent that. So now we're at a last resort: Implement the whole thing ourselves, but with Popup instead of Menu.
Contributes to issue CURA-8640.