forked from qt-creator/qt-creator
EditorManager: Add NoFlags as 0-option
Add NoFlags as 0 option to OpenEditorFlags. Change-Id: I33fca771b6c51442febff8a4bb3c06c844147758 Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
committed by
Eike Ziller
parent
bf75e5c085
commit
11cc292da6
@@ -98,6 +98,7 @@ public:
|
||||
static EditorToolBar *createToolBar(QWidget *parent = 0);
|
||||
|
||||
enum OpenEditorFlag {
|
||||
NoFlags = 0,
|
||||
DoNotChangeCurrentEditor = 1,
|
||||
IgnoreNavigationHistory = 2,
|
||||
DoNotMakeVisible = 4,
|
||||
@@ -108,9 +109,9 @@ public:
|
||||
|
||||
static QString splitLineNumber(QString *fileName);
|
||||
static IEditor *openEditor(const QString &fileName, const Id &editorId = Id(),
|
||||
OpenEditorFlags flags = 0, bool *newEditor = 0);
|
||||
OpenEditorFlags flags = NoFlags, bool *newEditor = 0);
|
||||
static IEditor *openEditorAt(const QString &fileName, int line, int column = 0,
|
||||
const Id &editorId = Id(), OpenEditorFlags flags = 0,
|
||||
const Id &editorId = Id(), OpenEditorFlags flags = NoFlags,
|
||||
bool *newEditor = 0);
|
||||
static IEditor *openEditorWithContents(const Id &editorId,
|
||||
QString *titlePattern = 0, const QByteArray &contents = QByteArray());
|
||||
@@ -259,11 +260,12 @@ private:
|
||||
|
||||
static IEditor *placeEditor(Internal::EditorView *view, IEditor *editor);
|
||||
static IEditor *duplicateEditor(IEditor *editor);
|
||||
static IEditor *activateEditor(Internal::EditorView *view, IEditor *editor, OpenEditorFlags flags = 0);
|
||||
static void activateEditorForEntry(Internal::EditorView *view, DocumentModel::Entry *entry, OpenEditorFlags flags = 0);
|
||||
static IEditor *activateEditor(Internal::EditorView *view, IEditor *editor, OpenEditorFlags flags = NoFlags);
|
||||
static void activateEditorForEntry(Internal::EditorView *view, DocumentModel::Entry *entry,
|
||||
OpenEditorFlags flags = NoFlags);
|
||||
static void activateView(Internal::EditorView *view);
|
||||
static IEditor *openEditor(Internal::EditorView *view, const QString &fileName,
|
||||
const Id &id = Id(), OpenEditorFlags flags = 0, bool *newEditor = 0);
|
||||
const Id &id = Id(), OpenEditorFlags flags = NoFlags, bool *newEditor = 0);
|
||||
static int visibleDocumentsCount();
|
||||
|
||||
static void setCurrentEditor(IEditor *editor, bool ignoreNavigationHistory = false);
|
||||
|
@@ -44,7 +44,7 @@ void VirtualFunctionProposalItem::apply(TextEditor::BaseTextEditor *, int) const
|
||||
if (!m_link.hasValidTarget())
|
||||
return;
|
||||
|
||||
Core::EditorManager::OpenEditorFlags flags;
|
||||
Core::EditorManager::OpenEditorFlags flags = Core::EditorManager::NoFlags;
|
||||
if (m_openInSplit)
|
||||
flags |= Core::EditorManager::OpenInOtherSplit;
|
||||
Core::EditorManager::openEditorAt(m_link.targetFileName,
|
||||
|
Reference in New Issue
Block a user