QmlJSEditor: Remove functions from widget that delegate to document

Instead access document directly. Needs to export document.

Change-Id: I8fa86832982d2793ea951e88a5b6e3925b7cd281
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
This commit is contained in:
Eike Ziller
2014-02-07 13:45:51 +01:00
parent 9167d4a16c
commit 89a2c4620b
11 changed files with 40 additions and 54 deletions

View File

@@ -530,13 +530,15 @@ void QmlJSEditorDocumentPrivate::updateOutlineModel()
m_outlineModel->update(m_semanticInfo);
}
} // Internal
QmlJSEditorDocument::QmlJSEditorDocument()
: m_d(new QmlJSEditorDocumentPrivate(this))
: m_d(new Internal::QmlJSEditorDocumentPrivate(this))
{
connect(this, SIGNAL(tabSettingsChanged()),
m_d, SLOT(invalidateFormatterCache()));
setSyntaxHighlighter(new Highlighter(document()));
setIndenter(new Indenter);
setIndenter(new Internal::Indenter);
}
QmlJSEditorDocument::~QmlJSEditorDocument()
@@ -559,7 +561,7 @@ QVector<QTextLayout::FormatRange> QmlJSEditorDocument::diagnosticRanges() const
return m_d->m_diagnosticRanges;
}
QmlOutlineModel *QmlJSEditorDocument::outlineModel() const
Internal::QmlOutlineModel *QmlJSEditorDocument::outlineModel() const
{
return m_d->m_outlineModel;
}
@@ -593,5 +595,4 @@ void QmlJSEditorDocument::triggerPendingUpdates()
}
}
} // Internal
} // QmlJSEditor