PopupMenu oddity with Cakewalk & Windows VST3

Hi!

If I try displaying a JUCE pop-up Window in Cakewalk from the Wotja 22 VST3 - there is really weird behaviour where the menu can take seconds to appear.

Furthermore, the menu is unresponsive, and you can see a vertical line from Cakewalk appear on top.

No such issue with Reaper.

Has anybody got any suggestions?

Best wishes to all, Pete

What sort of window are you using for testing? Is your menu completely custom, or do you see this with standard PopupMenu windows and ComboBoxes?

I just tried out the DSPModulePluginDemo VST3 in CakeWalk 2021.12 and the combo box menus seem to function correctly there.

Hi @reuk,

Thanks for getting back to me.

Not using any ComboBoxes.

Code like this:

  auto options = juce::PopupMenu::Options();
  mMenu.setLookAndFeel(&juce::LookAndFeel::getDefaultLookAndFeel());
  options.withStandardItemHeight(40).withMinimumWidth(200).withItemThatMustBeVisible(itemIDThatMustBeVisible);

  mMenu.showMenuAsync(options, mPrivateLambda);

The really weird thing is that when this runs, the whole of Cakewalk seems to repaint itself (and the plug-in) several times, every few seconds.

EDIT: again, to clarify: Reaper behaves 100% fine!

Pete

Is this with the latest version of Cakewalk? Perhaps this was a bug that was fixed in the newest version.

Hi @reuk - the very latest Cakewalk.

I can’t say that I noticed it before TBH; but then I do most of my Windows testing with Reaper.

Best wishes, Pete

This shows the weird effect where the Cakewalk UI draws a vertical in on top of the JUCE-based plug-in after having tried to display a PopupMenu…

Pete

@reuk just wondering, but do you have JUCE_MODAL_LOOPS_PERMITTED defined?

I don’t - but I just saw that in the implementation of the following, and wondered if signficant?

int PopupMenu::showWithOptionalCallback


       #if JUCE_MODAL_LOOPS_PERMITTED
        if (userCallback == nullptr && canBeModal)
            return window->runModalLoop();
       #else
        ignoreUnused (canBeModal);
        jassert (! (userCallback == nullptr && canBeModal));
       #endif

No, I was testing without JUCE_MODAL_LOOPS_PERMITTED too.

OK, thanks!!

Hi peteatjuce

Can you send us a version of your plugin that does this?
You can email me at noel at bandlab.com

1 Like

Hi @nborthwick !

You can simply download the latest copy of Wotja 22 Free from the Windows App Store!

I’ll mail you separately.

Best wishes, Pete

Hi Folks,

Just to report that thanks to some great feedback from the team at Cakewalk/Bandlab, I was able to track-down the bug in Wotja that was causing this issue.

Bottom line - I had some unwanted calls to repaint() that were causing too many paints to occur, and that clogged-up the painting process.

Best wishes to all, and many thanks to the Cakewalk team at Bandlab!

Pete

2 Likes