mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2024-12-03 11:24:10 +01:00
GCS ConnectionManager: Remove some commented code
This commit is contained in:
parent
44e7c4542f
commit
9912432e84
@ -44,25 +44,18 @@ namespace Core {
|
|||||||
|
|
||||||
|
|
||||||
ConnectionManager::ConnectionManager(Internal::MainWindow *mainWindow, QTabWidget *modeStack) :
|
ConnectionManager::ConnectionManager(Internal::MainWindow *mainWindow, QTabWidget *modeStack) :
|
||||||
QWidget(mainWindow), // Pip
|
QWidget(mainWindow),
|
||||||
m_availableDevList(0),
|
m_availableDevList(0),
|
||||||
m_connectBtn(0),
|
m_connectBtn(0),
|
||||||
m_ioDev(NULL),
|
m_ioDev(NULL),
|
||||||
m_mainWindow(mainWindow)
|
m_mainWindow(mainWindow)
|
||||||
{
|
{
|
||||||
// Q_UNUSED(mainWindow);
|
|
||||||
|
|
||||||
/* QVBoxLayout *top = new QVBoxLayout;
|
|
||||||
top->setSpacing(0);
|
|
||||||
top->setMargin(0);*/
|
|
||||||
|
|
||||||
QHBoxLayout *layout = new QHBoxLayout;
|
QHBoxLayout *layout = new QHBoxLayout;
|
||||||
layout->setSpacing(5);
|
layout->setSpacing(5);
|
||||||
layout->setContentsMargins(5,5,5,5);
|
layout->setContentsMargins(5,5,5,5);
|
||||||
layout->addWidget(new QLabel(tr("Connections:")));
|
layout->addWidget(new QLabel(tr("Connections:")));
|
||||||
|
|
||||||
m_availableDevList = new QComboBox;
|
m_availableDevList = new QComboBox;
|
||||||
//m_availableDevList->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);
|
|
||||||
m_availableDevList->setMinimumWidth(100);
|
m_availableDevList->setMinimumWidth(100);
|
||||||
m_availableDevList->setMaximumWidth(150);
|
m_availableDevList->setMaximumWidth(150);
|
||||||
m_availableDevList->setContextMenuPolicy(Qt::CustomContextMenu);
|
m_availableDevList->setContextMenuPolicy(Qt::CustomContextMenu);
|
||||||
@ -72,13 +65,8 @@ ConnectionManager::ConnectionManager(Internal::MainWindow *mainWindow, QTabWidge
|
|||||||
m_connectBtn->setEnabled(false);
|
m_connectBtn->setEnabled(false);
|
||||||
layout->addWidget(m_connectBtn);
|
layout->addWidget(m_connectBtn);
|
||||||
|
|
||||||
/* Utils::StyledBar *bar = new Utils::StyledBar;
|
|
||||||
bar->setLayout(layout);
|
|
||||||
|
|
||||||
top->addWidget(bar);*/
|
|
||||||
setLayout(layout);
|
setLayout(layout);
|
||||||
|
|
||||||
// modeStack->insertCornerWidget(modeStack->cornerWidgetCount()-1, this);
|
|
||||||
modeStack->setCornerWidget(this, Qt::TopRightCorner);
|
modeStack->setCornerWidget(this, Qt::TopRightCorner);
|
||||||
|
|
||||||
QObject::connect(m_connectBtn, SIGNAL(pressed()), this, SLOT(onConnectPressed()));
|
QObject::connect(m_connectBtn, SIGNAL(pressed()), this, SLOT(onConnectPressed()));
|
||||||
@ -86,8 +74,8 @@ ConnectionManager::ConnectionManager(Internal::MainWindow *mainWindow, QTabWidge
|
|||||||
|
|
||||||
ConnectionManager::~ConnectionManager()
|
ConnectionManager::~ConnectionManager()
|
||||||
{
|
{
|
||||||
disconnectDevice(); // Pip
|
disconnectDevice();
|
||||||
suspendPolling(); // Pip
|
suspendPolling();
|
||||||
}
|
}
|
||||||
|
|
||||||
void ConnectionManager::init()
|
void ConnectionManager::init()
|
||||||
|
Loading…
Reference in New Issue
Block a user