diff options
author | Eike Ziller <eike.ziller@digia.com> | 2014-01-10 15:32:03 +0100 |
---|---|---|
committer | Eike Ziller <eike.ziller@digia.com> | 2014-01-14 09:03:58 +0100 |
commit | cfad9bdc3cb9fba3a565eaf9ac4f62dcf880c661 (patch) | |
tree | e5ce3e489494c05eb670aec33723079954e4f628 /src/plugins/qmljseditor | |
parent | ad4b589231caa023fdb9f4a8e1ba42fbf593d06f (diff) |
TextEditors: Move contentsChanged signal from editor to document
Change-Id: Ic935a8971705cb3238deda71aa2b5d19e4f62593
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Diffstat (limited to 'src/plugins/qmljseditor')
-rw-r--r-- | src/plugins/qmljseditor/qmljseditorplugin.cpp | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/src/plugins/qmljseditor/qmljseditorplugin.cpp b/src/plugins/qmljseditor/qmljseditorplugin.cpp index 0cf2695503f..0820dd4b663 100644 --- a/src/plugins/qmljseditor/qmljseditorplugin.cpp +++ b/src/plugins/qmljseditor/qmljseditorplugin.cpp @@ -311,14 +311,12 @@ void QmlJSEditorPlugin::currentEditorChanged(Core::IEditor *editor) newTextEditor = qobject_cast<QmlJSTextEditorWidget *>(editor->widget()); if (m_currentEditor) { - disconnect(m_currentEditor.data(), SIGNAL(contentsChanged()), - this, SLOT(checkCurrentEditorSemanticInfoUpToDate())); - disconnect(m_currentEditor.data(), SIGNAL(semanticInfoUpdated()), - this, SLOT(checkCurrentEditorSemanticInfoUpToDate())); + m_currentEditor->baseTextDocument()->disconnect(this); + m_currentEditor->disconnect(this); } m_currentEditor = newTextEditor; if (newTextEditor) { - connect(newTextEditor, SIGNAL(contentsChanged()), + connect(newTextEditor->baseTextDocument(), SIGNAL(contentsChanged()), this, SLOT(checkCurrentEditorSemanticInfoUpToDate())); connect(newTextEditor, SIGNAL(semanticInfoUpdated()), this, SLOT(checkCurrentEditorSemanticInfoUpToDate())); |