diff options
author | Orgad Shaneh <orgad.shaneh@audiocodes.com> | 2016-06-27 22:34:13 +0300 |
---|---|---|
committer | Orgad Shaneh <orgads@gmail.com> | 2016-06-28 12:54:02 +0000 |
commit | 847637708f398af968d2163c907dbe3b93587699 (patch) | |
tree | bc98545456c854f2f30c04cd7ed987795ab8c42b /tests/manual/process | |
parent | 4d9f79964dc0eb1c24c84c753942f0c73488a414 (diff) |
Tests: Use Qt5-style connects
The heavy lifting was done by clazy.
Change-Id: If3332a2b4a6d011d2cb74996f5dd750452093f31
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'tests/manual/process')
-rw-r--r-- | tests/manual/process/mainwindow.cpp | 6 | ||||
-rw-r--r-- | tests/manual/process/mainwindow.h | 3 |
2 files changed, 3 insertions, 6 deletions
diff --git a/tests/manual/process/mainwindow.cpp b/tests/manual/process/mainwindow.cpp index a3ca20196d4..bd89d935cf8 100644 --- a/tests/manual/process/mainwindow.cpp +++ b/tests/manual/process/mainwindow.cpp @@ -37,7 +37,7 @@ MainWindow::MainWindow(QWidget *parent) : m_logWindow(new QPlainTextEdit) { setCentralWidget(m_logWindow); - QTimer::singleShot(200, this, SLOT(test())); + QTimer::singleShot(200, this, &MainWindow::test); } void MainWindow::append(const QString &s) @@ -54,8 +54,8 @@ void MainWindow::test() Utils::SynchronousProcess process; process.setTimeoutS(2); qDebug() << "Async: " << cmd << args; - connect(&process, SIGNAL(stdOut(QString,bool)), this, SLOT(append(QString))); - connect(&process, SIGNAL(stdErr(QString,bool)), this, SLOT(append(QString))); + connect(&process, &Utils::SynchronousProcess::stdOut, this, &MainWindow::append); + connect(&process, &Utils::SynchronousProcess::stdErr, this, &MainWindow::append); const Utils::SynchronousProcessResponse resp = process.run(cmd, args); qDebug() << resp; } diff --git a/tests/manual/process/mainwindow.h b/tests/manual/process/mainwindow.h index 6dfe3874000..3171b841f8b 100644 --- a/tests/manual/process/mainwindow.h +++ b/tests/manual/process/mainwindow.h @@ -37,9 +37,6 @@ Q_OBJECT public: explicit MainWindow(QWidget *parent = 0); -signals: - -public slots: void test(); void append(const QString &s); |