Autosaving works, and document and project tracks whether they have been changed or not.

This commit is contained in:
Veronica K. B. Olsen
2019-05-05 00:11:46 +02:00
parent 9ea70aeeaf
commit 9565b14d8b
8 changed files with 97 additions and 20 deletions
+2 -2
View File
@@ -204,7 +204,7 @@ class GuiDocEditor(QTextEdit):
self.wcTimer.start()
if self.mainConf.doReplace and not self.hasSelection:
self._docAutoReplace(self.theDoc.findBlock(thePos))
logger.verbose("Doc change signal took %.3f µs" % ((time()-self.lastEdit)*1e6))
# logger.verbose("Doc change signal took %.3f µs" % ((time()-self.lastEdit)*1e6))
return
def _docAutoReplace(self, theBlock):
@@ -267,7 +267,7 @@ class GuiDocEditor(QTextEdit):
"""
sinceActive = time()-self.lastEdit
if sinceActive > 5*self.wcInterval:
logger.verbose("Stopping word count timer due to no activity over the last %.3f seconds" % sinceActive)
logger.debug("Stopping word count timer due to no activity over the last %.3f seconds" % sinceActive)
self.wcTimer.stop()
elif self.wCounter.isRunning():
logger.verbose("Word counter thread is busy")