commit 511abbf4ce64b18c96ea0a17e2764b30e4faf070
Author: Juergen Spitzmueller <[email protected]>
Date:   Sat Mar 13 12:48:13 2021 +0100

    Backport QTime related deprecation fix
---
 src/support/FileName.cpp   |    6 +++---
 src/support/Systemcall.cpp |    4 ++--
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/src/support/FileName.cpp b/src/support/FileName.cpp
index a4075d6..482bb93 100644
--- a/src/support/FileName.cpp
+++ b/src/support/FileName.cpp
@@ -28,7 +28,7 @@
 #include <QFileInfo>
 #include <QList>
 #include <QTemporaryFile>
-#include <QTime>
+#include <QElapsedTimer>
 
 #ifdef _WIN32
 #include <QThread>
@@ -558,7 +558,7 @@ unsigned long FileName::checksum() const
        }
 
        // This is used in the debug output at the end of the method.
-       static QTime t;
+       static QElapsedTimer t;
        if (lyxerr.debugging(Debug::FILES))
                t.restart();
 
@@ -624,7 +624,7 @@ unsigned long FileName::checksum() const
 #endif // QT_VERSION
 
        LYXERR(Debug::FILES, "Checksumming \"" << absFileName() << "\" "
-               << result << " lasted " << t.elapsed() << " ms.");
+               << result << " lasted " << QString::number(t.elapsed()) << " 
ms.");
        return result;
 }
 
diff --git a/src/support/Systemcall.cpp b/src/support/Systemcall.cpp
index d4f71ff..58c2c22 100644
--- a/src/support/Systemcall.cpp
+++ b/src/support/Systemcall.cpp
@@ -30,7 +30,7 @@
 #include <iostream>
 
 #include <QProcess>
-#include <QTime>
+#include <QElapsedTimer>
 #include <QThread>
 #include <QCoreApplication>
 #include <QDebug>
@@ -446,7 +446,7 @@ bool SystemcallPrivate::waitWhile(State waitwhile, bool 
process_events, int time
        }
 
        // process events while waiting with timeout
-       QTime timer;
+       QElapsedTimer timer;
        timer.start();
        while (state == waitwhile && state != Error && !timedout) {
                waitAndProcessEvents();
-- 
lyx-cvs mailing list
[email protected]
http://lists.lyx.org/mailman/listinfo/lyx-cvs

Reply via email to