Commit 616ea2e5 authored by Orgad Shaneh's avatar Orgad Shaneh Committed by Orgad Shaneh
Browse files

Git: Fix opening repository log when commit editor is open

Opening a commit editor inside a submodule then executing
Local Repository Log opens the log for the supermodule.

Change-Id: I264925e0f23e2372a09a28e788174a747f5870a8
Reviewed-by: default avatarTobias Hunger <>
parent 5189c990
......@@ -1041,7 +1041,9 @@ Core::IEditor *GitPlugin::openSubmitEditor(const QString &fileName, const Commit
title = tr("Git Commit");
Core::IDocument *document = submitEditor->document();
VcsBasePlugin::setSource(document, m_submitRepository);
connect(submitEditor, SIGNAL(diff(QStringList,QStringList)), this, SLOT(submitEditorDiff(QStringList,QStringList)));
connect(submitEditor, SIGNAL(merge(QStringList)), this, SLOT(submitEditorMerge(QStringList)));
connect(submitEditor, SIGNAL(show(QString,QString)), m_gitClient, SLOT(show(QString,QString)));
......@@ -237,9 +237,8 @@ void StateListener::slotStateChanged()
} else {
state.currentFile = currentDocument->filePath();
if (state.currentFile.isEmpty()) {
if (state.currentFile.isEmpty() || currentDocument->isTemporary())
state.currentFile = VcsBasePlugin::source(currentDocument);
QScopedPointer<QFileInfo> currentFileInfo; // Instantiate QFileInfo only once if required.
if (!state.currentFile.isEmpty()) {
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment