Add DiffEditorManager, refactoring.

GitDiffSwitcher operates now on IDocument.
GitDiffHandler operates now on DiffEditorController.
"source" property now attached to editor's document (VcsBasePlugin).

Change-Id: Ie2570a597b8b992ac1dc33b9179eca459c8a751a
Reviewed-by: Tobias Hunger <tobias.hunger@digia.com>
Reviewed-by: Jarek Kobus <jaroslaw.kobus@digia.com>
This commit is contained in:
jkobus
2014-02-11 13:00:35 +01:00
committed by Jarek Kobus
parent 84e8a79c81
commit 73cf43f323
19 changed files with 445 additions and 266 deletions

View File

@@ -56,11 +56,9 @@ namespace VcsBase {
class VcsBaseEditorParameterWidget;
}
namespace Utils {
struct SynchronousProcessResponse;
}
namespace Utils { struct SynchronousProcessResponse; }
namespace DiffEditor { class DiffEditor; }
namespace DiffEditor { class DiffEditorDocument; }
namespace Git {
namespace Internal {
@@ -351,8 +349,6 @@ private:
QTextCodec *getSourceCodec(const QString &file) const;
VcsBase::VcsBaseEditorWidget *findExistingVCSEditor(const char *registerDynamicProperty,
const QString &dynamicPropertyValue) const;
DiffEditor::DiffEditor *findExistingDiffEditor(const char *registerDynamicProperty,
const QString &dynamicPropertyValue) const;
enum CodecType { CodecSource, CodecLogOutput, CodecNone };
VcsBase::VcsBaseEditorWidget *createVcsEditor(const Core::Id &kind,
@@ -362,11 +358,9 @@ private:
const char *registerDynamicProperty,
const QString &dynamicPropertyValue,
VcsBase::VcsBaseEditorParameterWidget *configWidget) const;
DiffEditor::DiffEditor *createDiffEditor(const char *registerDynamicProperty,
const QString &dynamicPropertyValue,
DiffEditor::DiffEditorDocument *createDiffEditor(const QString documentId,
const QString &source,
const QString &titlePattern,
const Core::Id editorId) const;
const QString &title) const;
VcsBase::Command *createCommand(const QString &workingDirectory,
VcsBase::VcsBaseEditorWidget* editor = 0,