Version control: Do not keep lock on message file while committing.

Store the file name and do not keep the QTemporaryFile around,
which still seems to maintain some kind of lock on Windows although
it is closed.
This commit is contained in:
Friedemann Kleint
2009-09-22 12:23:44 +02:00
parent 0134fb682d
commit 5aa65b12f3
8 changed files with 116 additions and 107 deletions

View File

@@ -44,7 +44,6 @@
QT_BEGIN_NAMESPACE
class QFile;
class QAction;
class QTemporaryFile;
QT_END_NAMESPACE
namespace Core {
@@ -128,9 +127,10 @@ private slots:
void push();
private:
bool isCommitEditorOpen() const;
QFileInfo currentFile() const;
Core::IEditor *openSubmitEditor(const QString &fileName, const CommitData &cd);
void cleanChangeTmpFile();
void cleanCommitMessageFile();
static GitPlugin *m_instance;
Core::ICore *m_core;
@@ -166,7 +166,7 @@ private:
QString m_submitRepository;
QStringList m_submitOrigCommitFiles;
QStringList m_submitOrigDeleteFiles;
QTemporaryFile *m_changeTmpFile;
QString m_commitMessageFileName;
bool m_submitActionTriggered;
};