Commit 841cfa64 authored by lm's avatar lm

Slight persistence adaptions. Now improving UI before taking video

parent e9035f5b
...@@ -87,6 +87,13 @@ border: 1px solid #777777; ...@@ -87,6 +87,13 @@ border: 1px solid #777777;
background: white; background: white;
} }
QGCToolWidgetItem {
border: 1px solid #66666B;
border-radius: 3px;
padding: 10px 0px 0px 0px;
margin-top: 1ex; /* leave space at the top for the title */
}
QDockWidget { QDockWidget {
border: 1px solid #32345E; border: 1px solid #32345E;
/* titlebar-close-icon: url(close.png); /* titlebar-close-icon: url(close.png);
......
...@@ -153,6 +153,7 @@ FORMS += src/ui/MainWindow.ui \ ...@@ -153,6 +153,7 @@ FORMS += src/ui/MainWindow.ui \
src/ui/designer/QGCToolWidget.ui \ src/ui/designer/QGCToolWidget.ui \
src/ui/designer/QGCParamSlider.ui \ src/ui/designer/QGCParamSlider.ui \
src/ui/designer/QGCActionButton.ui \ src/ui/designer/QGCActionButton.ui \
src/ui/designer/QGCCommandButton.ui \
src/ui/QGCMAVLinkLogPlayer.ui \ src/ui/QGCMAVLinkLogPlayer.ui \
src/ui/QGCWaypointListMulti.ui \ src/ui/QGCWaypointListMulti.ui \
src/ui/mission/QGCCustomWaypointAction.ui \ src/ui/mission/QGCCustomWaypointAction.ui \
...@@ -264,6 +265,7 @@ HEADERS += src/MG.h \ ...@@ -264,6 +265,7 @@ HEADERS += src/MG.h \
src/ui/designer/QGCToolWidget.h \ src/ui/designer/QGCToolWidget.h \
src/ui/designer/QGCParamSlider.h \ src/ui/designer/QGCParamSlider.h \
src/ui/designer/QGCActionButton.h \ src/ui/designer/QGCActionButton.h \
src/ui/designer/QGCCommandButton.h \
src/ui/designer/QGCToolWidgetItem.h \ src/ui/designer/QGCToolWidgetItem.h \
src/ui/QGCMAVLinkLogPlayer.h \ src/ui/QGCMAVLinkLogPlayer.h \
src/comm/MAVLinkSimulationWaypointPlanner.h \ src/comm/MAVLinkSimulationWaypointPlanner.h \
...@@ -394,6 +396,7 @@ SOURCES += src/main.cc \ ...@@ -394,6 +396,7 @@ SOURCES += src/main.cc \
src/ui/designer/QGCToolWidget.cc \ src/ui/designer/QGCToolWidget.cc \
src/ui/designer/QGCParamSlider.cc \ src/ui/designer/QGCParamSlider.cc \
src/ui/designer/QGCActionButton.cc \ src/ui/designer/QGCActionButton.cc \
src/ui/designer/QGCCommandButton.cc \
src/ui/designer/QGCToolWidgetItem.cc \ src/ui/designer/QGCToolWidgetItem.cc \
src/ui/QGCMAVLinkLogPlayer.cc \ src/ui/QGCMAVLinkLogPlayer.cc \
src/comm/MAVLinkSimulationWaypointPlanner.cc \ src/comm/MAVLinkSimulationWaypointPlanner.cc \
......
...@@ -1059,7 +1059,6 @@ void UAS::setHomePosition(double lat, double lon, double alt) ...@@ -1059,7 +1059,6 @@ void UAS::setHomePosition(double lat, double lon, double alt)
void UAS::setLocalOriginAtCurrentGPSPosition() void UAS::setLocalOriginAtCurrentGPSPosition()
{ {
bool result = false; bool result = false;
QMessageBox msgBox; QMessageBox msgBox;
msgBox.setIcon(QMessageBox::Warning); msgBox.setIcon(QMessageBox::Warning);
......
...@@ -307,9 +307,11 @@ void MainWindow::buildCustomWidget() ...@@ -307,9 +307,11 @@ void MainWindow::buildCustomWidget()
if (!dock) if (!dock)
{ {
QDockWidget* dock = new QDockWidget(widgets.at(i)->windowTitle(), this); QDockWidget* dock = new QDockWidget(widgets.at(i)->windowTitle(), this);
dock->setObjectName(widgets.at(i)->objectName()+"_DOCK");
dock->setWidget(widgets.at(i)); dock->setWidget(widgets.at(i));
connect(widgets.at(i), SIGNAL(destroyed()), dock, SLOT(deleteLater())); connect(widgets.at(i), SIGNAL(destroyed()), dock, SLOT(deleteLater()));
QAction* showAction = new QAction(widgets.at(i)->windowTitle(), this); QAction* showAction = new QAction(widgets.at(i)->windowTitle(), this);
showAction->setCheckable(true);
connect(showAction, SIGNAL(triggered(bool)), dock, SLOT(setVisible(bool))); connect(showAction, SIGNAL(triggered(bool)), dock, SLOT(setVisible(bool)));
connect(dock, SIGNAL(visibilityChanged(bool)), showAction, SLOT(setChecked(bool))); connect(dock, SIGNAL(visibilityChanged(bool)), showAction, SLOT(setChecked(bool)));
widgets.at(i)->setMainMenuAction(showAction); widgets.at(i)->setMainMenuAction(showAction);
...@@ -1045,6 +1047,7 @@ void MainWindow::createCustomWidget() ...@@ -1045,6 +1047,7 @@ void MainWindow::createCustomWidget()
connect(tool, SIGNAL(destroyed()), dock, SLOT(deleteLater())); connect(tool, SIGNAL(destroyed()), dock, SLOT(deleteLater()));
dock->setWidget(tool); dock->setWidget(tool);
QAction* showAction = new QAction("Show Unnamed Tool", this); QAction* showAction = new QAction("Show Unnamed Tool", this);
showAction->setCheckable(true);
connect(dock, SIGNAL(visibilityChanged(bool)), showAction, SLOT(setChecked(bool))); connect(dock, SIGNAL(visibilityChanged(bool)), showAction, SLOT(setChecked(bool)));
connect(showAction, SIGNAL(triggered(bool)), dock, SLOT(setVisible(bool))); connect(showAction, SIGNAL(triggered(bool)), dock, SLOT(setVisible(bool)));
tool->setMainMenuAction(showAction); tool->setMainMenuAction(showAction);
......
...@@ -203,7 +203,7 @@ void WaypointView::updateActionView(int action) ...@@ -203,7 +203,7 @@ void WaypointView::updateActionView(int action)
m_ui->orbitSpinBox->show(); m_ui->orbitSpinBox->show();
m_ui->holdTimeSpinBox->show(); m_ui->holdTimeSpinBox->show();
break; break;
case MAV_CMD_NAV_TARGET: case MAV_CMD_NAV_ORIENTATION_TARGET:
m_ui->orbitSpinBox->hide(); m_ui->orbitSpinBox->hide();
m_ui->takeOffAngleSpinBox->hide(); m_ui->takeOffAngleSpinBox->hide();
m_ui->turnsSpinBox->hide(); m_ui->turnsSpinBox->hide();
......
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