Git: Do not accept invalid commits

Do not offer to commit in the dialog opened when closing the
commit editor when the commit is not containing all the required
information.
This commit is contained in:
Tobias Hunger
2010-11-23 14:40:52 +01:00
parent f3b5c98bf5
commit 2f07660e5b
4 changed files with 32 additions and 13 deletions

View File

@@ -756,8 +756,8 @@ bool GitPlugin::submitEditorAboutToClose(VCSBase::VCSBaseSubmitEditor *submitEdi
const VCSBase::VCSBaseSubmitEditor::PromptSubmitResult answer =
editor->promptSubmit(tr("Closing Git Editor"),
tr("Do you want to commit the change?"),
tr("The commit message check failed. Do you want to commit the change?"),
&settings.promptToSubmit, !m_submitActionTriggered);
tr("Git will not accept this commit. Do you want to continue to edit it?"),
&settings.promptToSubmit, !m_submitActionTriggered, false);
m_submitActionTriggered = false;
switch (answer) {
case VCSBase::VCSBaseSubmitEditor::SubmitCanceled: