Mercurial > hg > easyhg
comparison 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 |
comparison
equal
deleted
inserted
replaced
89:622da79c0f4f | 90:b43355c2473a |
---|---|
22 #include "hgrunner.h" | 22 #include "hgrunner.h" |
23 #include "common.h" | 23 #include "common.h" |
24 | 24 |
25 #include <QMainWindow> | 25 #include <QMainWindow> |
26 #include <QListWidget> | 26 #include <QListWidget> |
27 #include <QFileSystemWatcher> | |
27 | 28 |
28 QT_BEGIN_NAMESPACE | 29 QT_BEGIN_NAMESPACE |
29 class QAction; | 30 class QAction; |
30 class QMenu; | 31 class QMenu; |
31 QT_END_NAMESPACE | 32 QT_END_NAMESPACE |
114 void hgResolveMark(); | 115 void hgResolveMark(); |
115 void hgTag(); | 116 void hgTag(); |
116 void hgServe(); | 117 void hgServe(); |
117 void hgIgnore(); | 118 void hgIgnore(); |
118 | 119 |
120 void fsDirectoryChanged(QString); | |
121 void fsFileChanged(QString); | |
122 | |
119 private: | 123 private: |
120 void hgHeads(); | 124 void hgHeads(); |
121 void hgParents(); | 125 void hgParents(); |
122 void hgLog(); | 126 void hgLog(); |
123 void createActions(); | 127 void createActions(); |
125 void createMenus(); | 129 void createMenus(); |
126 void createToolBars(); | 130 void createToolBars(); |
127 void createStatusBar(); | 131 void createStatusBar(); |
128 void readSettings(); | 132 void readSettings(); |
129 void splitChangeSets(QStringList *list, QString hgLogOutput); | 133 void splitChangeSets(QStringList *list, QString hgLogOutput); |
130 int getCommentOrTag(QString& commentOrTag, QString question, QString dlgTitle); | 134 bool getCommentOrTag(QString& commentOrTag, QString question, QString dlgTitle); |
131 void presentLongStdoutToUser(QString stdo); | 135 void presentLongStdoutToUser(QString stdo); |
132 void countModifications(QListWidget *workList, int& added, int& modified, int& removed, int& notTracked, | 136 void countModifications(QListWidget *workList, int& added, int& modified, int& removed, int& notTracked, |
133 int& selected, | 137 int& selected, |
134 int& selectedAdded, int& selectedModified, int& selectedRemoved, int& selectedNotTracked); | 138 int& selectedAdded, int& selectedModified, int& selectedRemoved, int& selectedNotTracked); |
135 bool isSelectedModified(QListWidget *workList); | 139 bool isSelectedModified(QListWidget *workList); |
155 | 159 |
156 bool askToInitExisting(QString); | 160 bool askToInitExisting(QString); |
157 bool askToInitNew(QString); | 161 bool askToInitNew(QString); |
158 bool askToOpenParentRepo(QString, QString); | 162 bool askToOpenParentRepo(QString, QString); |
159 bool askToOpenInsteadOfInit(QString); | 163 bool askToOpenInsteadOfInit(QString); |
164 | |
165 void updateFileSystemWatcher(); | |
160 | 166 |
161 bool firstStart; | 167 bool firstStart; |
162 | 168 |
163 //Actions enabled flags | 169 //Actions enabled flags |
164 bool remoteRepoActionsEnabled; | 170 bool remoteRepoActionsEnabled; |
208 QToolBar *workFolderToolBar; | 214 QToolBar *workFolderToolBar; |
209 | 215 |
210 HGACTIONS runningAction; | 216 HGACTIONS runningAction; |
211 HgRunner *runner; | 217 HgRunner *runner; |
212 | 218 |
219 QFileSystemWatcher *fsWatcher; | |
220 | |
213 int tabPage; | 221 int tabPage; |
214 unsigned char initialFileTypesBits; | 222 unsigned char initialFileTypesBits; |
215 bool justMerged; | 223 bool justMerged; |
216 }; | 224 }; |
217 | 225 |