View Single Post
d-iivil's Avatar
Posts: 2,154 | Thanked: 2,186 times | Joined on Dec 2009 @ Hellsinki, Finland
#73
Originally Posted by Diph View Post
It should be connect(..., this, SLOT(processFinished(int) or you can define the method void processFinished() if you don't need the exit code.

In header file (*.h) you declare methods and in source file (*.cpp) you write the implementation. Method declarations and implementations have to be in same form, like

Header:
Code:
class MainWindow
{
...
private:
   void processFinished(int code);
Cpp:
Code:
void MainWindow::processFinished(int code)
{
}
Actually you can make the connect without less attributes:
Code:
connect(progress, SIGNAL(finished(int, QString), this, SLOT(progressFinisshed(int));
and it should work.
Yeah, got it connecting by adding the int.

But about the script not running issue; it looks like there's something wrong with this:
Code:
        QProcess *process = new QProcess(this);
        process->start("/sbin/launchblack", arguments);
since it starts fine with this:
Code:
QProcess::execute("/sbin/launchblack", arguments);
__________________
If you're rich and you think I deserve a cold beer, you may donate one or two :-P

80's style stadium rock is back - FIRENOTE
Hi-Octane heavy metal - FORCE MAJEURE