diff options
author | Andrea Diamantini <adjam7@gmail.com> | 2008-12-06 23:30:36 +0100 |
---|---|---|
committer | Andrea Diamantini <adjam7@gmail.com> | 2008-12-06 23:30:36 +0100 |
commit | a02a9101fe127211de1fd24f6876b87686309997 (patch) | |
tree | 5ce7921378ef55ac963f2946f6c00f85d0ab7445 /src/autosaver.cpp | |
parent | ctrl + tab switching: try 5.. (diff) | |
download | rekonq-a02a9101fe127211de1fd24f6876b87686309997.tar.xz |
QTabWidget --> KTabWidget
Diffstat (limited to 'src/autosaver.cpp')
-rw-r--r-- | src/autosaver.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/src/autosaver.cpp b/src/autosaver.cpp index 4b83b65d..c1164e60 100644 --- a/src/autosaver.cpp +++ b/src/autosaver.cpp @@ -20,25 +20,26 @@ #include "autosaver.h" -#include <QtCore/QDir> -#include <QtCore/QCoreApplication> -#include <QtCore/QMetaObject> +#include <QtCore> #include <QtDebug> #define AUTOSAVE_IN 1000 * 3 // seconds #define MAXWAIT 1000 * 15 // seconds + AutoSaver::AutoSaver(QObject *parent) : QObject(parent) { Q_ASSERT(parent); } + AutoSaver::~AutoSaver() { if (m_timer.isActive()) qWarning() << "AutoSaver: still active when destroyed, changes not saved."; } + void AutoSaver::changeOccurred() { if (m_firstChange.isNull()) @@ -51,6 +52,7 @@ void AutoSaver::changeOccurred() } } + void AutoSaver::timerEvent(QTimerEvent *event) { if (event->timerId() == m_timer.timerId()) { @@ -60,6 +62,7 @@ void AutoSaver::timerEvent(QTimerEvent *event) } } + void AutoSaver::saveIfNeccessary() { if (!m_timer.isActive()) |