Pārlūkot izejas kodu

QDateTime::msecsTo is not available in Qt 4.6.3

Achieve the same operation using QTime object associated with QDateTime
Jean-Christophe Fillion-Robin 14 gadi atpakaļ
vecāks
revīzija
914dfa7767
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      Libs/Core/ctkErrorLogModel.cpp

+ 1 - 1
Libs/Core/ctkErrorLogModel.cpp

@@ -259,7 +259,7 @@ void ctkErrorLogModel::addEntry(ctkErrorLogModel::LogLevel logLevel,
     QDateTime lastRowDateTime = QDateTime::fromString(lastRowTimeIndex.data().toString(), timeFormat);
 
     int groupingIntervalInMsecs = 1000;
-    bool withinGroupingInterval = lastRowDateTime.msecsTo(currentDateTime) <= groupingIntervalInMsecs;
+    bool withinGroupingInterval = lastRowDateTime.time().msecsTo(currentDateTime.time()) <= groupingIntervalInMsecs;
 
     groupEntry = logLevelMatched && originMatched && withinGroupingInterval;
     }