TextEditor: Use Qt5-style connects

The heavy lifting was done by clazy.

Change-Id: I380120e3419d2a3c0e272f51cc3e0d5f6aaa5e9b
Reviewed-by: Tobias Hunger <tobias.hunger@theqtcompany.com>
This commit is contained in:
Orgad Shaneh
2015-12-13 01:18:33 +02:00
committed by Orgad Shaneh
parent b6131e1b1d
commit 9d3b2f0998
53 changed files with 314 additions and 339 deletions

View File

@@ -33,6 +33,7 @@
#include <coreplugin/coreicons.h>
#include <coreplugin/icore.h>
#include <coreplugin/editormanager/editormanager.h>
#include <coreplugin/editormanager/ieditor.h>
#include <QToolButton>
#include <QLabel>
@@ -62,7 +63,8 @@ OutlineWidgetStack::OutlineWidgetStack(OutlineFactory *factory) :
m_toggleSync->setCheckable(true);
m_toggleSync->setChecked(true);
m_toggleSync->setToolTip(tr("Synchronize with Editor"));
connect(m_toggleSync, SIGNAL(clicked(bool)), this, SLOT(toggleCursorSynchronization()));
connect(m_toggleSync, &QAbstractButton::clicked,
this, &OutlineWidgetStack::toggleCursorSynchronization);
m_filterButton = new QToolButton;
m_filterButton->setIcon(Core::Icons::FILTER.icon());
@@ -72,8 +74,8 @@ OutlineWidgetStack::OutlineWidgetStack(OutlineFactory *factory) :
m_filterMenu = new QMenu(m_filterButton);
m_filterButton->setMenu(m_filterMenu);
connect(Core::EditorManager::instance(), SIGNAL(currentEditorChanged(Core::IEditor*)),
this, SLOT(updateCurrentEditor(Core::IEditor*)));
connect(Core::EditorManager::instance(), &Core::EditorManager::currentEditorChanged,
this, &OutlineWidgetStack::updateCurrentEditor);
updateCurrentEditor(Core::EditorManager::currentEditor());
}