Menubar malfunction



On my windows xp/sp3 system if I were to start the stock audio plugin host demo and then click in the menubar and then begin mousing around all over the menu items and categories like a beginner will do as they learn what menu options are where - I can reliably if not predictably get the menu bar to ‘freeze’. It stays on-screen but is no longer paying attention to the mouse and the only way to clear it is to bring another application to the front (from the windows startbar) and then switch back to the juce application. At which point things clear up. I can always make it happen within say 15-20 seconds of ‘mousing all over the menus’ but haven’t yet found an exact sequence of ‘mousing around’ to trigger it.

Since I based my application from the audio plugin host my app has this problem as well and I just checked Jucer and I can break its menu bar as well. I noticed the juce application is ‘flickering’ in the windows start bar when this happens.

Has anybody else noticed this?
I’m pretty sure I’m using juce 1.53 (how do I find out exactly which version if I can’t remember?)

Clarification, by ‘mousing around’ I menu clicking once in the menubar to cause the menu to popdown, then without clicking begin moving the mouse from item to item, highlighting it, traversing into submenus and back out, then going back to the top and waving over another menu category (causing it to drop down) etc. In other words I’m only clicking the mouse once then just moving it randomly (and quickly) around to ‘see’ what’s available.



I’ve never seen it myself, but if you can let me know how to reproduce it, let me know!


The best way to reproduce it is to just click in the menu bar and then begin quickly moving the mouse into and out of every menu option and category you can without clicking anything. It usually occurs fairly rapidly. I guess the odds are the users won’t encounter this as it appears to be rare to non-existent during normal use but if you have a chance to investigate this I’d appreciate it.


The malfunction MIGHT be triggered when having moused into a submenu - you then quickly traverse to the menubar and select another category. It’s hard to tell for sure.


Well, spent a minute doing that and nothing happened… Don’t want to spend hours randomly jiggling the mouse, but if you can tell me something that definitely causes it, I’ll try again.


I’ve the same problem here on a Windows 7 (64 bit) system and I can confirm that it appears only when adding the
There is also a strange side effect and maybe this could help: entering with the mouse inside the submenus seems to
disable the “focused” state of the application icon on the Windows taskbar and when the menu freezes the taskbar
icon flashes continuously … similarly to a deadlock.

However, quickly investigating inside the “juce_popupmenu.cpp” code I’ve found that remming out the line 390 “if
(makeInvisible && (deletionChecker != nullptr))” seems to resolve the issue (at least the “freezing” one) … but I
don’t know exacly why (it was just a shot in the dark) … Jules, could you give us some lights? Thanks!

To reproduce the issue (Juce 1.53):

  1. create at least two menus
  2. inside each menu create some single items and at least two items with some subitems
  3. run the program, select a menu on the menubar and move the mouse on the first menu item which contains the
    subitems and after on the second one … in this manner the application lose the focus on the taskbar (at least
  4. now move the mouse on the second menu of the menubar and the focus magically reappears … but after playing a
    little with the mouse on the other menu items we get the freezing issue.

Take a look at the screenshot too …