diff options
| author | Edward Welbourne <edward.welbourne@qt.io> | 2020-07-23 13:54:47 +0200 |
|---|---|---|
| committer | Edward Welbourne <edward.welbourne@qt.io> | 2020-07-27 11:20:35 +0200 |
| commit | 02c2c930f0874a8886cb0983606c38cb8b356cd7 (patch) | |
| tree | 501d5fc16f2ba14f02bb27a75964ffe8993510d0 /tests/manual/textrendering/textperformance/main.cpp | |
| parent | 2059170b33ffb05b99d9a3e1e374eb5a4bce9163 (diff) | |
Fix some compiler errors caused by bit-rot in manual tests
Two methods that have gone away or been renamed,
an enum that now doesn't support being assigned from int.
QTime should no longer be used as a timer.
Removed a test of deprecated code that's gone away.
Task-number: QTBUG-85700
Change-Id: Idc6d59542625d22b9937084411b54b0d8aa87f00
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/manual/textrendering/textperformance/main.cpp')
| -rw-r--r-- | tests/manual/textrendering/textperformance/main.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/tests/manual/textrendering/textperformance/main.cpp b/tests/manual/textrendering/textperformance/main.cpp index eb6d09b9c8b..8fb3a3c4a27 100644 --- a/tests/manual/textrendering/textperformance/main.cpp +++ b/tests/manual/textrendering/textperformance/main.cpp @@ -1,6 +1,6 @@ /**************************************************************************** ** -** Copyright (C) 2016 The Qt Company Ltd. +** Copyright (C) 2020 The Qt Company Ltd. ** Contact: https://www.qt.io/licensing/ ** ** This file is part of the test suite of the Qt Toolkit. @@ -31,7 +31,7 @@ #include <QFontDatabase> #include <QPainter> #include <QRandomGenerator> -#include <QTime> +#include <QElapsedTimer> #include <QTimer> static const int lastMeasurementsCount = 50; @@ -53,7 +53,7 @@ public: Q_UNUSED(event); QPainter p(this); - if (!m_timer.isNull()) + if (m_timer.isValid()) m_lastMeasurements.append(m_timer.elapsed()); m_timer.start(); @@ -195,7 +195,7 @@ private: int m_currentMode; QList<int> m_lastMeasurements; - QTime m_timer; + QElapsedTimer m_timer; }; const struct FontBlaster::mode FontBlaster::m_modes[] = { |
