How can I open a DialogWindow or DocumentWindow non modal?
I’ve tried to create a derived DocumentWindow instance from the main app and I managed to be non modal, but the main window lost its focus and it stop doing its repaint until it regain the focus.
What are you doing? Any window which become visible is non modal by default.
The new window has to update its visual information ( by paint() ) but also the main window. Is something similar when a plug-in window is open in a host.
By now, I managed to creat the new window but the host window stop painting its content until it retake the focus.
Repainting and modality are completely unrelated… If a component stops repainting, it’s because you’ve stopped calling repaint, not because something is modal.
Jules, I was tracing the code and my component does not repaint because when the repaint() method reach the Component class (juce_component.cpp), the flag flags.hasHeavyweightPeerFlag is false.
Why is it turned off?
Hi Jules, Hi all,
I realized that HasHeavyweightPeerFlag has nothing to do with my issue, sorry for that.
But, I’ve trace until the Win API and the Stack is the following:
> juce::HWNDComponentPeer::repaint C++
[Los marcos siguientes pueden no ser correctos o faltar, no se han cargado símbolos para kernel32.dll]
Same stack trace happens if the main window (CArrayComponent) has the focus or the secondary window, as it must be. But, if the secondary window has the focus, the main window is not repainted.
My knowledge ends here, I cannot imagine why happens that.
Do you have any idea, please? I am deeply stuck with this problem.
Gabriel, it seems you doing something unusual, and with you given information its almost impossible to help. We can’t read your mind. Thats why you don’t get any help.
So if you want some help, please post as much information we need (maybe the whole project as zip-archive) or something similar that makes it possible to reconstruct the problem in a few seconds.
You’re misunderstanding something, but I’m not sure exactly what it is!
When you get stuck on a problem like this, a good approach might be to try building a minimal test app to replicate the problem?
Chkn, Jules, Thank you.
Without any doubt, you are right.
I have to build a mock-up.