mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-03-31 21:15:33 +08:00
refs #768, misc adjustments
* changed signature of ownAircraftModelChanged to model * added function for a reverse lookup of a model (string->model) and use it when model changed * renamed function to updateByLocalFileNames
This commit is contained in:
committed by
Mathew Sutcliffe
parent
501bea0960
commit
bf8198e2c2
@@ -81,7 +81,7 @@ namespace BlackSimPlugin
|
||||
CAircraftModel newModel(model);
|
||||
newModel.setModelType(CAircraftModel::TypeOwnSimulatorModel);
|
||||
updateOwnModel(newModel);
|
||||
emit ownAircraftModelChanged(getOwnAircraft());
|
||||
emit ownAircraftModelChanged(newModel);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -102,7 +102,8 @@ namespace BlackSimPlugin
|
||||
m_fastTimer->start(100);
|
||||
m_slowTimer->start(1000);
|
||||
|
||||
m_defaultModel = {
|
||||
m_defaultModel =
|
||||
{
|
||||
"Jets A320_a A320_a_Austrian_Airlines A320_a_Austrian_Airlines",
|
||||
CAircraftModel::TypeModelMatchingDefaultModel,
|
||||
"A320 AUA",
|
||||
@@ -309,10 +310,9 @@ namespace BlackSimPlugin
|
||||
model.setFileName(path + "/" + filename);
|
||||
model.setLivery(CLivery("XPLANE." + livery, airlineIcaoCode, "XP livery", "", "", false));
|
||||
|
||||
// updates
|
||||
updateOwnIcaoCodes(model.getAircraftIcaoCode(), airlineIcaoCode);
|
||||
updateOwnModel(model);
|
||||
emit ownAircraftModelChanged(getOwnAircraft());
|
||||
// updated model.
|
||||
// Hint: will update in own model context by using reverse lookup
|
||||
emit ownAircraftModelChanged(model);
|
||||
}
|
||||
|
||||
void CSimulatorXPlane::displayStatusMessage(const BlackMisc::CStatusMessage &message) const
|
||||
|
||||
Reference in New Issue
Block a user