QProcess, how to give focus to the new process on Mac
My application on Mac starts another process using QProcess.
The new application started using QProcess is hidden behind the original application.
The problem is that I do not have the code for the application which I start using QProcess, so I need to give it access from my Qt based application.
I will truly appreciate the help,
Ashraf Sultan
Simulation Lab Software
www.simlab-soft.com
Re: QProcess, how to give focus to the new process on Mac
By "giving access" you mean to activate its window and bring it to front? There is no simple way to do this. It would be probably easiest if you just minimized the window of your application but there is no guarantee there won't be other windows obscuring the one you want.
Re: QProcess, how to give focus to the new process on Mac
Thank you for the suggestion. I will try it.
I was hoping that Mac has a C/C++ function which gives the focus to a process based on its process ID.
QProcess already returns PID.
Re: QProcess, how to give focus to the new process on Mac
It probably has such a function somewhere. But that's certainly not a simple solution.