I have a QtSingleApplication.
I've started an instance A.
Next I start an instance B.
B uses sendmessage()
to send a message to A.
A uses this message ( received with messageReceived()
signal )to determine whether B should continue running or not.
How do I inform B of this decision?
I had thought of inserting the process ID of B..with the message sent to A, and using this process ID, perhaps A can force B's closure or have it continue?
If this is a correct flow, how do I get the process Id ( I don't know whether there'll be one for QtSingleApplication, or for a process, and if Pid QProcess::processID() ), will be any good? ).
Also, once I have it, how do I force B's closure? Or inform it of any message?
Thank you for your help.