From d06c98edeebe44ed9de255bbf9abf5be11190576 Mon Sep 17 00:00:00 2001 From: Don Gagne Date: Thu, 4 Dec 2014 09:40:21 -0800 Subject: [PATCH] Remove unused selectSystem slot --- src/ui/linechart/Linecharts.cc | 31 +------------------------------ src/ui/linechart/Linecharts.h | 2 -- 2 files changed, 1 insertion(+), 32 deletions(-) diff --git a/src/ui/linechart/Linecharts.cc b/src/ui/linechart/Linecharts.cc index 750e08202..6e97aaef4 100644 --- a/src/ui/linechart/Linecharts.cc +++ b/src/ui/linechart/Linecharts.cc @@ -18,10 +18,7 @@ Linecharts::Linecharts(QWidget *parent) : foreach (UASInterface* sys, systems) { addSystem(sys); } - connect(UASManager::instance(), SIGNAL(UASCreated(UASInterface*)), - this, SLOT(addSystem(UASInterface*))); - connect(UASManager::instance(), SIGNAL(activeUASSet(int)), - this, SLOT(selectSystem(int))); + connect(UASManager::instance(), &UASManager::UASCreated, this, &Linecharts::addSystem); } void Linecharts::showEvent(QShowEvent* event) @@ -59,32 +56,6 @@ void Linecharts::hideEvent(QHideEvent* event) emit visibilityChanged(false); } -void Linecharts::selectSystem(int systemid) -{ - Q_UNUSED(systemid); -// QWidget* prevWidget = currentWidget(); -// if (prevWidget) -// { -// LinechartWidget* chart = dynamic_cast(prevWidget); -// if (chart) -// { -// chart->setActive(false); -// chart->setActiveSystem(systemid); -// } -// } -// QWidget* widget = plots.value(systemid, NULL); -// if (widget) -// { -// setCurrentWidget(widget); -// LinechartWidget* chart = dynamic_cast(widget); -// if (chart) -// { -// chart->setActive(true); -// chart->setActiveSystem(systemid); -// } -// } -} - void Linecharts::addSystem(UASInterface* uas) { // FIXME Add removeSystem() call diff --git a/src/ui/linechart/Linecharts.h b/src/ui/linechart/Linecharts.h index 20474b760..ced7734eb 100644 --- a/src/ui/linechart/Linecharts.h +++ b/src/ui/linechart/Linecharts.h @@ -20,8 +20,6 @@ signals: void visibilityChanged(bool visible); public slots: - /** @brief Select plot for one system */ - void selectSystem(int systemid); /** @brief Add a new system to the list of plots */ void addSystem(UASInterface* uas); /** @brief Add a new generic message source (not a system) */ -- 2.22.0