mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2024-12-02 10:24:11 +01:00
Merge branch 'rel-14.10' into laurent/rel-14.10_Translations_updates
This commit is contained in:
commit
2ccc5165d3
@ -173,7 +173,7 @@ void AirframeInitialTuningPage::loadValidFiles()
|
||||
QJsonParseError error;
|
||||
QJsonDocument templateDoc = QJsonDocument::fromJson(jsonData, &error);
|
||||
if (error.error == QJsonParseError::NoError) {
|
||||
QJsonObject json = templateDoc.object();
|
||||
QJsonObject json = templateDoc.object();
|
||||
if (json["type"].toInt() == getWizard()->getVehicleType() &&
|
||||
json["subtype"].toInt() == getWizard()->getVehicleSubType()) {
|
||||
QString uuid = json["uuid"].toString();
|
||||
|
@ -160,8 +160,8 @@ void EscCalibrationPage::stopButtonClicked()
|
||||
void EscCalibrationPage::securityCheckBoxesToggled()
|
||||
{
|
||||
ui->startButton->setEnabled(ui->securityCheckBox1->isChecked() &&
|
||||
ui->securityCheckBox2->isChecked() &&
|
||||
ui->securityCheckBox3->isChecked());
|
||||
ui->securityCheckBox2->isChecked() &&
|
||||
ui->securityCheckBox3->isChecked());
|
||||
}
|
||||
|
||||
|
||||
|
@ -214,18 +214,18 @@ void VehicleTemplateExportDialog::accept()
|
||||
|
||||
const char *fileType = ".optmpl";
|
||||
|
||||
QString fileName = QString("%1-%2-%3%4")
|
||||
.arg(fixFilenameString(ui->Name->text(), 20))
|
||||
.arg(fixFilenameString(ui->Type->text(), 30))
|
||||
.arg(fixFilenameString(uuid.toString().right(12)))
|
||||
.arg(fileType);
|
||||
QString fileName = QString("%1-%2-%3%4")
|
||||
.arg(fixFilenameString(ui->Name->text(), 20))
|
||||
.arg(fixFilenameString(ui->Type->text(), 30))
|
||||
.arg(fixFilenameString(uuid.toString().right(12)))
|
||||
.arg(fileType);
|
||||
|
||||
QString fullPath = QString("%1%2%3%4%5")
|
||||
.arg(EXPORT_BASE_NAME)
|
||||
.arg(QDir::separator())
|
||||
.arg(getTypeDirectory())
|
||||
.arg(QDir::separator())
|
||||
.arg(fileName);
|
||||
.arg(EXPORT_BASE_NAME)
|
||||
.arg(QDir::separator())
|
||||
.arg(getTypeDirectory())
|
||||
.arg(QDir::separator())
|
||||
.arg(fileName);
|
||||
|
||||
QDir dir = QFileInfo(fullPath).absoluteDir();
|
||||
if (!dir.exists()) {
|
||||
@ -243,7 +243,7 @@ void VehicleTemplateExportDialog::accept()
|
||||
saveFile.write(saveDoc.toJson());
|
||||
saveFile.close();
|
||||
} else {
|
||||
QMessageBox::information(this, "Export", tr("Settings could not be exported to \n%1(%2).\nPlease try again.")
|
||||
QMessageBox::information(this, "Export", tr("Settings could not be exported to \n%1(%2).\nPlease try again.")
|
||||
.arg(QFileInfo(saveFile).absoluteFilePath(), saveFile.error()), QMessageBox::Ok);
|
||||
}
|
||||
QDialog::accept();
|
||||
|
@ -55,11 +55,11 @@ WelcomePlugin::~WelcomePlugin()
|
||||
// The below code is commented out to avoid having the application
|
||||
// crash when it is terminated. TODO: Fix a real solution.
|
||||
/*
|
||||
if (m_welcomeMode) {
|
||||
if (m_welcomeMode) {
|
||||
removeObject(m_welcomeMode);
|
||||
delete m_welcomeMode;
|
||||
}
|
||||
*/
|
||||
}
|
||||
*/
|
||||
}
|
||||
|
||||
/*! Initializes the plugin. Returns true on success.
|
||||
|
Loading…
Reference in New Issue
Block a user