diff mainwindow.h @ 90:b43355c2473a

* Add filesystem watcher; initial work on enable/disable logic for actions in new scheme
author Chris Cannam
date Tue, 23 Nov 2010 16:35:49 +0000
parents 8a4e26dc3182
children 44ed7766d55a
line wrap: on
line diff
--- a/mainwindow.h	Tue Nov 23 14:49:13 2010 +0000
+++ b/mainwindow.h	Tue Nov 23 16:35:49 2010 +0000
@@ -24,6 +24,7 @@
 
 #include <QMainWindow>
 #include <QListWidget>
+#include <QFileSystemWatcher>
 
 QT_BEGIN_NAMESPACE
 class QAction;
@@ -116,6 +117,9 @@
     void hgServe();
     void hgIgnore();
 
+    void fsDirectoryChanged(QString);
+    void fsFileChanged(QString);
+
 private:
     void hgHeads();
     void hgParents();
@@ -127,7 +131,7 @@
     void createStatusBar();
     void readSettings();
     void splitChangeSets(QStringList *list, QString hgLogOutput);
-    int getCommentOrTag(QString& commentOrTag, QString question, QString dlgTitle);
+    bool getCommentOrTag(QString& commentOrTag, QString question, QString dlgTitle);
     void presentLongStdoutToUser(QString stdo);
     void countModifications(QListWidget *workList, int& added, int& modified, int& removed, int& notTracked,
         int& selected,
@@ -158,6 +162,8 @@
     bool askToOpenParentRepo(QString, QString);
     bool askToOpenInsteadOfInit(QString);
 
+    void updateFileSystemWatcher();
+
     bool firstStart;
 
     //Actions enabled flags
@@ -210,6 +216,8 @@
     HGACTIONS   runningAction;
     HgRunner    *runner;
 
+    QFileSystemWatcher *fsWatcher;
+
     int             tabPage;
     unsigned char   initialFileTypesBits;
     bool            justMerged;