mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-26 10:45:37 +08:00
Avoid shutdown if modal window closes
See https://discordapp.com/channels/539048679160676382/567139633964646411/613564665255034903
This commit is contained in:
committed by
Mat Sutcliffe
parent
d9948af103
commit
92f3dd392f
@@ -555,7 +555,7 @@ namespace BlackGui
|
|||||||
void CFlightPlanComponent::loadFromDisk()
|
void CFlightPlanComponent::loadFromDisk()
|
||||||
{
|
{
|
||||||
CStatusMessageList msgs;
|
CStatusMessageList msgs;
|
||||||
const QString fileName = QFileDialog::getOpenFileName(nullptr, tr("Load flight plan"), this->getDefaultFilename(true), "Flight plans (*.json *.sfp *.vfp *.xml);;swift (*.json *.txt);;SimBrief (*.xml);;vPilot (*.vfp);;SB4 (*.sfp)");
|
const QString fileName = QFileDialog::getOpenFileName(this, tr("Load flight plan"), this->getDefaultFilename(true), "Flight plans (*.json *.sfp *.vfp *.xml);;swift (*.json *.txt);;SimBrief (*.xml);;vPilot (*.vfp);;SB4 (*.sfp)");
|
||||||
if (fileName.isEmpty()) { return; }
|
if (fileName.isEmpty()) { return; }
|
||||||
CFlightPlan fp = CFlightPlan::loadFromMultipleFormats(fileName, &msgs);
|
CFlightPlan fp = CFlightPlan::loadFromMultipleFormats(fileName, &msgs);
|
||||||
if (!fp.hasCallsign()) { fp.setCallsign(ui->le_Callsign->text()); } // set callsign if it wasn't set
|
if (!fp.hasCallsign()) { fp.setCallsign(ui->le_Callsign->text()); } // set callsign if it wasn't set
|
||||||
|
|||||||
Reference in New Issue
Block a user