Commit 0f89c838 authored by Michael Carpenter's avatar Michael Carpenter

Some comment cleanup, and fix so when closing the main window, it also closes...

Some comment cleanup, and fix so when closing the main window, it also closes the item select window
parent 07c10d10
......@@ -16,69 +16,8 @@ UASQuickView::UASQuickView(QWidget *parent) : QWidget(parent)
}
this->setContextMenuPolicy(Qt::ActionsContextMenu);
/*{
QAction *action = new QAction("latitude",this);
action->setCheckable(true);
action->setChecked(true);
connect(action,SIGNAL(toggled(bool)),this,SLOT(actionTriggered(bool)));
this->addAction(action);
UASQuickViewItem *item = new UASQuickViewItem(this);
item->setTitle("latitude");
ui.verticalLayout->addWidget(item);
uasPropertyToLabelMap["latitude"] = item;
}
{
QAction *action = new QAction("longitude",this);
action->setCheckable(true);
action->setChecked(true);
connect(action,SIGNAL(toggled(bool)),this,SLOT(actionTriggered(bool)));
this->addAction(action);
UASQuickViewItem *item = new UASQuickViewItem(this);
item->setTitle("longitude");
ui.verticalLayout->addWidget(item);
uasPropertyToLabelMap["longitude"] = item;
}
{
QAction *action = new QAction("altitude",this);
action->setCheckable(true);
action->setChecked(true);
connect(action,SIGNAL(toggled(bool)),this,SLOT(actionTriggered(bool)));
this->addAction(action);
UASQuickViewItem *item = new UASQuickViewItem(this);
item->setTitle("altitude");
ui.verticalLayout->addWidget(item);
uasPropertyToLabelMap["altitude"] = item;
}
{
QAction *action = new QAction("satelliteCount",this);
action->setCheckable(true);
action->setChecked(true);
connect(action,SIGNAL(toggled(bool)),this,SLOT(actionTriggered(bool)));
this->addAction(action);
UASQuickViewItem *item = new UASQuickViewItem(this);
item->setTitle("satelliteCount");
ui.verticalLayout->addWidget(item);
uasPropertyToLabelMap["satelliteCount"] = item;
}
{
QAction *action = new QAction("distToWaypoint",this);
action->setCheckable(true);
action->setChecked(true);
connect(action,SIGNAL(toggled(bool)),this,SLOT(actionTriggered(bool)));
this->addAction(action);
UASQuickViewItem *item = new UASQuickViewItem(this);
item->setTitle("distToWaypoint");
ui.verticalLayout->addWidget(item);
uasPropertyToLabelMap["distToWaypoint"] = item;
}*/
//this->setSizePolicy();
loadSettings();
//If we don't have any predefined settings, set some defaults.
if (uasPropertyValueMap.size() == 0)
{
......@@ -98,6 +37,14 @@ UASQuickView::UASQuickView(QWidget *parent) : QWidget(parent)
connect(updateTimer,SIGNAL(timeout()),this,SLOT(updateTimerTick()));
updateTimer->start(1000);
}
UASQuickView::~UASQuickView()
{
if (quickViewSelectDialog)
{
delete quickViewSelectDialog;
}
}
void UASQuickView::actionTriggered()
{
if (quickViewSelectDialog)
......
......@@ -15,6 +15,7 @@ class UASQuickView : public QWidget
Q_OBJECT
public:
UASQuickView(QWidget *parent = 0);
~UASQuickView();
void addSource(MAVLinkDecoder *decoder);
private:
UASInterface *uas;
......
......@@ -6,12 +6,12 @@
<rect>
<x>0</x>
<y>0</y>
<width>851</width>
<height>192</height>
<width>947</width>
<height>248</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
<string>Select Item</string>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
......@@ -24,8 +24,8 @@
<rect>
<x>0</x>
<y>0</y>
<width>831</width>
<height>172</height>
<width>927</width>
<height>228</height>
</rect>
</property>
<layout class="QVBoxLayout" name="verticalLayout_2">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment