From 83f8d886cee0a40ac1ad5e43e597f309f602ad76 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Fri, 12 Jul 2019 13:17:02 +0200 Subject: Fix some compiler warnings in tests - Signedness of integer comparison - Unused parameters and variables - Ignored return values of QTest::qWaitForWindowExposed() (nodiscard) - float to int conversions Change-Id: Ibece620d3c980a5af3b7717486c841d8072ed8af Reviewed-by: Simon Hausmann --- tests/auto/quick/scenegraph/tst_scenegraph.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'tests/auto/quick/scenegraph/tst_scenegraph.cpp') diff --git a/tests/auto/quick/scenegraph/tst_scenegraph.cpp b/tests/auto/quick/scenegraph/tst_scenegraph.cpp index c15f1e941e..3f605348c3 100644 --- a/tests/auto/quick/scenegraph/tst_scenegraph.cpp +++ b/tests/auto/quick/scenegraph/tst_scenegraph.cpp @@ -75,8 +75,8 @@ public: delete node; node = new QSGNode; - const int w = width(); - const int h = height(); + const int w = int(width()); + const int h = int(height()); QQuickWindow *win = window(); for (int y = 0; y < h; ++y) { for (int x = 0; x < w; ++x) { @@ -569,8 +569,8 @@ bool tst_SceneGraph::isRunningOnOpenGLDirectly() decided = true; QQuickView dummy; dummy.show(); - QTest::qWaitForWindowExposed(&dummy); - retval = dummy.rendererInterface()->graphicsApi() == QSGRendererInterface::OpenGL; + if (QTest::qWaitForWindowExposed(&dummy)) + retval = dummy.rendererInterface()->graphicsApi() == QSGRendererInterface::OpenGL; dummy.hide(); } return retval; -- cgit v1.2.3