diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.cpp b/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.cpp
index 0e392bd56..ab506ccd6 100644
--- a/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.cpp
+++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.cpp
@@ -45,11 +45,8 @@ FixedWingPage::FixedWingPage(SetupWizard *wizard, QWidget *parent) :
setupFixedWingTypesCombo();
// Default to Aileron setup
- ui->typeCombo->setCurrentIndex(0);
connect(ui->typeCombo, SIGNAL(currentIndexChanged(int)), this, SLOT(updateImageAndDescription()));
- ui->typeGraphicsView->setSceneRect(m_fixedwingPic->boundingRect());
- ui->typeGraphicsView->fitInView(m_fixedwingPic, Qt::KeepAspectRatio);
-
+ ui->typeCombo->setCurrentIndex(0);
}
FixedWingPage::~FixedWingPage()
@@ -71,15 +68,26 @@ bool FixedWingPage::validatePage()
return true;
}
-void FixedWingPage::resizeEvent(QResizeEvent *event)
+void FixedWingPage::fitInView()
{
- Q_UNUSED(event);
if (m_fixedwingPic) {
ui->typeGraphicsView->setSceneRect(m_fixedwingPic->boundingRect());
ui->typeGraphicsView->fitInView(m_fixedwingPic, Qt::KeepAspectRatio);
}
}
+void FixedWingPage::resizeEvent(QResizeEvent *event)
+{
+ Q_UNUSED(event);
+ fitInView();
+}
+
+void FixedWingPage::showEvent(QShowEvent *event)
+{
+ Q_UNUSED(event);
+ fitInView();
+}
+
void FixedWingPage::setupFixedWingTypesCombo()
{
ui->typeCombo->addItem(tr("Aileron Dual Servos"), SetupWizard::FIXED_WING_DUAL_AILERON);
@@ -98,8 +106,6 @@ void FixedWingPage::updateAvailableTypes()
void FixedWingPage::updateImageAndDescription()
{
-
-
SetupWizard::VEHICLE_SUB_TYPE type = (SetupWizard::VEHICLE_SUB_TYPE)ui->typeCombo->itemData(ui->typeCombo->currentIndex()).toInt();
QString elementId = "";
QString description = m_descriptions.at(ui->typeCombo->currentIndex());
@@ -125,4 +131,3 @@ void FixedWingPage::updateImageAndDescription()
ui->typeDescription->setText(description);
}
-
diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.h b/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.h
index 593be37bb..5c50adcba 100644
--- a/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.h
+++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/fixedwingpage.h
@@ -48,8 +48,10 @@ public:
void initializePage();
bool validatePage();
+ void fitInView();
protected:
void resizeEvent(QResizeEvent *event);
+ void showEvent(QShowEvent *event);
private:
Ui::FixedWingPage *ui;
@@ -60,6 +62,7 @@ private:
private slots:
void updateImageAndDescription();
+
};
#endif // FIXEDWINGPAGE_H
diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/outputcalibrationpage.cpp b/ground/openpilotgcs/src/plugins/setupwizard/pages/outputcalibrationpage.cpp
index 4865e9b13..969d88472 100644
--- a/ground/openpilotgcs/src/plugins/setupwizard/pages/outputcalibrationpage.cpp
+++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/outputcalibrationpage.cpp
@@ -185,12 +185,12 @@ void OutputCalibrationPage::setupVehicle()
break;
case SetupWizard::FIXED_WING_AILERON:
loadSVGFile(FIXEDWING_SVG_FILE);
- m_wizardIndexes << 0 << 1 << 2 << 3 << 4 << 2 << 3 << 4 << 2 << 3 << 4 << 2 << 3 << 4;
- m_vehicleElementIds << "aileron-single" << "ail2-frame" << "ail2-motor" << "ail2-ail-left" << "ail2-ail-right" << "ail2-rudder" << "ail2-elevator";
- m_vehicleHighlightElementIndexes << 0 << 1 << 2 << 2 << 2 << 3 << 3 << 3 << 4 << 4 << 4 << 5 << 5 << 5;
- m_channelIndex << 0 << 2 << 0 << 0 << 0 << 1 << 1 << 1 << 3 << 3 << 3 << 4 << 4 << 4;
+ m_wizardIndexes << 0 << 1 << 2 << 3 << 4 << 2 << 3 << 4 << 2 << 3 << 4;
+ m_vehicleElementIds << "aileron-single" << "ail2-frame" << "ail2-motor" << "ail2-aileron" << "ail2-rudder" << "ail2-elevator";
+ m_vehicleHighlightElementIndexes << 0 << 1 << 2 << 2 << 2 << 3 << 3 << 3 << 4 << 4 << 4;
+ m_channelIndex << 0 << 2 << 0 << 0 << 0 << 4 << 4 << 4 << 1 << 1 << 1;
- setupActuatorMinMaxAndNeutral(3, 3, 5);
+ setupActuatorMinMaxAndNeutral(3, 3, 4);
getWizard()->setActuatorSettings(m_actuatorSettings);
break;
diff --git a/ground/openpilotgcs/src/plugins/setupwizard/pages/vehiclepage.cpp b/ground/openpilotgcs/src/plugins/setupwizard/pages/vehiclepage.cpp
index eac4c9a02..a9c476cdc 100644
--- a/ground/openpilotgcs/src/plugins/setupwizard/pages/vehiclepage.cpp
+++ b/ground/openpilotgcs/src/plugins/setupwizard/pages/vehiclepage.cpp
@@ -59,6 +59,6 @@ bool VehiclePage::validatePage()
void VehiclePage::initializePage()
{
- ui->fixedwingButton->setEnabled(getWizard()->getControllerType() == SetupWizard::CONTROLLER_REVO ||
- getWizard()->getControllerType() == SetupWizard::CONTROLLER_NANO);
+ //ui->fixedwingButton->setEnabled(getWizard()->getControllerType() == SetupWizard::CONTROLLER_REVO ||
+ // getWizard()->getControllerType() == SetupWizard::CONTROLLER_NANO);
}
diff --git a/ground/openpilotgcs/src/plugins/setupwizard/resources/fixedwing-shapes.svg b/ground/openpilotgcs/src/plugins/setupwizard/resources/fixedwing-shapes.svg
index 968c38041..07d7fe2d0 100644
--- a/ground/openpilotgcs/src/plugins/setupwizard/resources/fixedwing-shapes.svg
+++ b/ground/openpilotgcs/src/plugins/setupwizard/resources/fixedwing-shapes.svg
@@ -19,4106 +19,4074 @@
viewBox="0 0 792 2400"
enable-background="new 0 0 792 1008"
xml:space="preserve"
- inkscape:version="0.48.5 r10040"
+ inkscape:version="0.48.4 r9939"
sodipodi:docname="fixedwing-shapes.svg">image/svg+xml
-
-image/svg+xml6
+
+
+
+
+4
+6
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-4
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-4
-
-
-
\ No newline at end of file
+ height="36.404999"
+ id="rect3816-4" />
+
+
+
+4
+
\ No newline at end of file