When a submenu is open and you move the mouse towards it, the submenu stays open even if the cursor crosses other submenus. That's good if you want to access this submenu. If you don't want to access this submenu, it may take up to 1 second until the toolbox responds again.
(Test it: open toolbox, wait until submenu pops up, move mouse towards a submenu-entry but stop the mouse before you reach the submenu. Now the cursor is above another entry in the top-menu, but it doesn't respond)
My patch checks if the mouse has stopped, and if so, it processes the item under the cursor.
I'm not sure if the original behaviour is wrong or if that's just my opinion. Please have a good look at it.
Another thing in my patch:
I moved the "PIL_sleep_ms(10);" on top of the loop.
Otherwise, we have two "uiGetMouse" following each other immediately in the first pass => dx, dy = 0. But that's just cosmetics ;-)
Description
Description