fix: use QElapsedTimer instead of QTime

Fixes the following warning:
```
/build/gio-qt/src/gio-qt-0.0.12/gio-qt/source/dgiofile.cpp:228:20: warning: ‘void QTime::start()’ is deprecated: Use QElapsedTimer instead [-Wdeprecated-declarations]
  228 |             t.start();
      |             ~~~~~~~^~
```
This commit is contained in:
Felix Yan 2023-09-15 18:23:40 +03:00 committed by deepin-bot[bot]
parent 0c5f4347f5
commit 412b307f0b

View File

@ -16,7 +16,7 @@
#include <QDebug> #include <QDebug>
#include <QWaitCondition> #include <QWaitCondition>
#include <QMutex> #include <QMutex>
#include <QTime> #include <QElapsedTimer>
#include <QtConcurrent/QtConcurrentRun> #include <QtConcurrent/QtConcurrentRun>
#include <dgiomountoperation.h> #include <dgiomountoperation.h>
@ -224,7 +224,7 @@ QExplicitlySharedDataPointer<DGioFileInfo> DGioFile::createFileInfo(QString attr
QSharedPointer<QMutex> m(new QMutex); QSharedPointer<QMutex> m(new QMutex);
QtConcurrent::run([&, cond, m, timeout_msec] { QtConcurrent::run([&, cond, m, timeout_msec] {
Glib::RefPtr<FileInfo> localret; Glib::RefPtr<FileInfo> localret;
QTime t; QElapsedTimer t;
t.start(); t.start();
try { try {
localret = d->getGmmFileInstance()->query_info(attr.toStdString(), flags); localret = d->getGmmFileInstance()->query_info(attr.toStdString(), flags);