diff options
author | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-08-28 15:16:57 +0200 |
---|---|---|
committer | Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> | 2015-09-02 10:21:56 +0000 |
commit | c726bc85da3921c6a31d4f7d014ddd8b8d7a3f88 (patch) | |
tree | ed9cef6e31acb5881a77473e4f12a90b3c9ea426 /examples/opengl/hellowindow | |
parent | 4b340402b97b83790b3d71a8244a246eec4f8abd (diff) |
Port examples/opengl to new connection syntax.
Change-Id: I486a4a2326bf57ec5ea08bccdcef79c3e5553db5
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Diffstat (limited to 'examples/opengl/hellowindow')
-rw-r--r-- | examples/opengl/hellowindow/hellowindow.cpp | 4 | ||||
-rw-r--r-- | examples/opengl/hellowindow/main.cpp | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/examples/opengl/hellowindow/hellowindow.cpp b/examples/opengl/hellowindow/hellowindow.cpp index 7674ffaed8..bc58e1a0e4 100644 --- a/examples/opengl/hellowindow/hellowindow.cpp +++ b/examples/opengl/hellowindow/hellowindow.cpp @@ -119,7 +119,7 @@ void Renderer::setAnimating(HelloWindow *window, bool animating) if (animating) { m_windows << window; if (m_windows.size() == 1) - QTimer::singleShot(0, this, SLOT(render())); + QTimer::singleShot(0, this, &Renderer::render); } else { m_currentWindow = 0; m_windows.removeOne(window); @@ -184,7 +184,7 @@ void Renderer::render() m_fAngle += 1.0f; - QTimer::singleShot(0, this, SLOT(render())); + QTimer::singleShot(0, this, &Renderer::render); } Q_GLOBAL_STATIC(QMutex, initMutex) diff --git a/examples/opengl/hellowindow/main.cpp b/examples/opengl/hellowindow/main.cpp index 716280aa5f..f665ee6fa8 100644 --- a/examples/opengl/hellowindow/main.cpp +++ b/examples/opengl/hellowindow/main.cpp @@ -121,13 +121,13 @@ int main(int argc, char *argv[]) } for (int i = 0; i < renderThreads.size(); ++i) { - QObject::connect(qGuiApp, SIGNAL(lastWindowClosed()), renderThreads.at(i), SLOT(quit())); + QObject::connect(qGuiApp, &QGuiApplication::lastWindowClosed, renderThreads.at(i), &QThread::quit); renderThreads.at(i)->start(); } // Quit after 10 seconds. For platforms that do not have windows that are closeable. if (QCoreApplication::arguments().contains(QStringLiteral("--timeout"))) - QTimer::singleShot(10000, qGuiApp, SLOT(quit())); + QTimer::singleShot(10000, qGuiApp, &QCoreApplication::quit); const int exitValue = app.exec(); |