TextEditors: Remove widget's setTabSettings method

Change-Id: If212b45e2d526534b7853f3fa23b170f61e1976e
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
This commit is contained in:
Eike Ziller
2014-01-17 17:09:15 +01:00
parent f506104f29
commit 4eff289e03
16 changed files with 102 additions and 62 deletions

View File

@@ -761,6 +761,18 @@ void QmlJSTextEditorWidget::updateOutlineIndexNow()
}
}
QmlJSEditorDocument::QmlJSEditorDocument()
{
connect(this, SIGNAL(tabSettingsChanged()),
this, SLOT(invalidateFormatterCache()));
}
void QmlJSEditorDocument::invalidateFormatterCache()
{
QmlJSTools::CreatorCodeFormatter formatter(tabSettings());
formatter.invalidateCache(document());
}
} // namespace QmlJSEditor
class QtQuickToolbarMarker {};
@@ -1286,14 +1298,6 @@ void QmlJSTextEditorWidget::unCommentSelection()
Utils::unCommentSelection(this);
}
void QmlJSTextEditorWidget::setTabSettings(const TextEditor::TabSettings &ts)
{
QmlJSTools::CreatorCodeFormatter formatter(ts);
formatter.invalidateCache(document());
TextEditor::BaseTextEditorWidget::setTabSettings(ts);
}
void QmlJSTextEditorWidget::updateSemanticInfo()
{
// If the editor is newer than the future semantic info, new semantic infos