minor change

This commit is contained in:
Roy Qu 2023-01-15 13:54:37 +08:00
parent aa62f95cad
commit 48446aab02
1 changed files with 2 additions and 2 deletions

View File

@ -1908,7 +1908,7 @@ void Editor::onAutoBackupTimer()
if (mBackupTime>lastModifyTime())
return;
QDateTime current=QDateTime::currentDateTime();
if (current.toSecsSinceEpoch()-lastModifyTime().toSecsSinceEpoch()<3)
if (current.toSecsSinceEpoch()-lastModifyTime().toSecsSinceEpoch()<=3)
return;
saveAutoBackup();
}
@ -3355,7 +3355,7 @@ void Editor::saveAutoBackup()
mBackupTime=QDateTime::currentDateTime();
mBackupFile->write(text().toUtf8());
mBackupFile->flush();
qDebug()<<mBackupTime<<mBackupFile->size()<<mBackupFile->fileName();
//qDebug()<<mBackupTime<<mBackupFile->size()<<mBackupFile->fileName();
}
}