mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-06 10:15:38 +08:00
refs #395, changed own aircraft provider to thread safe member functions
(similar to remote aircraft provider)
* removed references
* made own aircraft context thread safe (reg. own aircrat data)
* removed the read only versions of the provider
* adjusted consuming methods
* renamed some functions ("ownAircraft...") to avoid ambiguity (with remote aircraft)
This commit is contained in:
committed by
Mathew Sutcliffe
parent
7200f2e29c
commit
3ecf37dda4
@@ -185,8 +185,8 @@ namespace BlackGui
|
||||
ownAircraft.setCallsign(aircraftValues.ownCallsign);
|
||||
|
||||
// set latest ICAO, callsign
|
||||
this->getIContextOwnAircraft()->updateIcaoData(ownAircraft.getIcaoInfo());
|
||||
this->getIContextOwnAircraft()->updateCallsign(ownAircraft.getCallsign());
|
||||
this->getIContextOwnAircraft()->updateOwnIcaoData(ownAircraft.getIcaoInfo());
|
||||
this->getIContextOwnAircraft()->updateOwnCallsign(ownAircraft.getCallsign());
|
||||
|
||||
// Login mode
|
||||
INetwork::LoginMode mode = ui->gbp_LoginMode->getLoginMode();
|
||||
@@ -216,7 +216,7 @@ namespace BlackGui
|
||||
currentServer = this->getCurrentOtherServer();
|
||||
}
|
||||
this->ui->frp_CurrentServer->setServer(currentServer);
|
||||
this->getIContextOwnAircraft()->updatePilot(currentServer.getUser());
|
||||
this->getIContextOwnAircraft()->updateOwnAircraftPilot(currentServer.getUser());
|
||||
|
||||
// Login
|
||||
msg = this->getIContextNetwork()->connectToNetwork(currentServer, static_cast<uint>(mode));
|
||||
@@ -470,7 +470,7 @@ namespace BlackGui
|
||||
|
||||
// set value in backend
|
||||
this->mergeGuiIcaoValues(icao);
|
||||
this->getIContextOwnAircraft()->updateIcaoData(icao);
|
||||
this->getIContextOwnAircraft()->updateOwnIcaoData(icao);
|
||||
|
||||
// update GUI
|
||||
this->setGuiIcaoValues(icao, false);
|
||||
|
||||
Reference in New Issue
Block a user