Getting void mouseMagnify() to work


On my Windows 10 machine, I’m running the following line of code:

 void mouseMagnify(const MouseEvent& mouse, float scale) override { DBG(scale); }

But it doesn’t respond at all when I test it.

I’ve tried it in a variety of Components and projects. Is there something I’m missing?


Can you override any other mouse functions on your component?

What happens when you do:

// Click anywhere in your component to test
void mouseDown (const MouseEvent& event) override { DBG("TEST"); } 

mouseMagnify is called when a pinch-to-zoom mouse-gesture is used. How are you emitting that “signal”?


Other mouse functions such as mouseDown are working as I would expect them to.

To test mouseMagnify I’m holding the mouse over the given component and then pinch-zooming on my trackpad, and nothing happens. I’ve also tested to make sure that the component has keyboard focus, and it does.

Obviously the message is being lost somewhere upstream, but I don’t know where to look.


I’m getting the same result as you. I can pinch zoom in the Windows10 Photos app with my track pad, but nothing happens in the JUCE component.

My Laptop is a 2018 Dell Vostro.