forked from qt-creator/qt-creator
Git: Update file model after unsuccessful commit
The commit operation itself [un]stages files before actually committing. The model has to be refreshed after that. Change-Id: I4b765005640b62812687d4f003d94af3717c379e Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
committed by
Orgad Shaneh
parent
23b8e6d531
commit
a39516aef1
@@ -1078,6 +1078,7 @@ bool GitPlugin::submitEditorAboutToClose()
|
||||
|
||||
if (!m_gitClient->addAndCommit(m_submitRepository, editor->panelData(), commitType,
|
||||
amendSHA1, m_commitMessageFileName, model)) {
|
||||
editor->updateFileModel();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -62,10 +62,10 @@ public:
|
||||
GitSubmitEditorPanelData panelData() const;
|
||||
CommitType commitType() const { return m_commitType; }
|
||||
QString amendSHA1() const;
|
||||
void updateFileModel() override;
|
||||
|
||||
protected:
|
||||
QByteArray fileContents() const override;
|
||||
void updateFileModel() override;
|
||||
void forceUpdateFileModel();
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user