forked from qt-creator/qt-creator
Merge remote-tracking branch 'origin/3.1'
Conflicts: qtcreator.pri qtcreator.qbs src/shared/qbs Change-Id: Iba59e41db72e2afdf594f1f7003215d7d8d1e6d3
This commit is contained in:
@@ -216,8 +216,6 @@ DocumentManager::DocumentManager(QObject *parent)
|
||||
{
|
||||
d = new DocumentManagerPrivate;
|
||||
m_instance = this;
|
||||
connect(ICore::instance(), SIGNAL(contextChanged(QList<Core::IContext*>,Core::Context)),
|
||||
this, SLOT(syncWithEditor(QList<Core::IContext*>)));
|
||||
qApp->installEventFilter(this);
|
||||
|
||||
readSettings();
|
||||
@@ -1129,22 +1127,6 @@ void DocumentManager::checkForReload()
|
||||
// dump();
|
||||
}
|
||||
|
||||
void DocumentManager::syncWithEditor(const QList<Core::IContext *> &context)
|
||||
{
|
||||
if (context.isEmpty())
|
||||
return;
|
||||
|
||||
Core::IEditor *editor = Core::EditorManager::currentEditor();
|
||||
if (!editor || editor->document()->isTemporary())
|
||||
return;
|
||||
foreach (IContext *c, context) {
|
||||
if (editor->widget() == c->widget()) {
|
||||
setCurrentFile(editor->document()->filePath());
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/*!
|
||||
Adds the \a fileName to the list of recent files. Associates the file to
|
||||
be reopened with the editor that has the specified \a editorId, if possible.
|
||||
|
Reference in New Issue
Block a user