mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-03 15:45:46 +08:00
refs #253, faster updates of ATC stations by changedAtcStationConnectionStatus(const
This commit is contained in:
@@ -37,6 +37,7 @@ namespace BlackGui
|
||||
Q_ASSERT(this->getIContextNetwork());
|
||||
this->connect(this->getIContextNetwork(), &IContextNetwork::changedAtcStationsOnline, this, &CAtcStationComponent::changedAtcStationsOnline);
|
||||
this->connect(this->getIContextNetwork(), &IContextNetwork::changedAtcStationsBooked, this, &CAtcStationComponent::changedAtcStationsBooked);
|
||||
this->connect(this->getIContextNetwork(), &IContextNetwork::changedAtcStationOnlineConnectionStatus, this, &CAtcStationComponent::changedAtcStationOnlineConnectionStatus);
|
||||
}
|
||||
|
||||
void CAtcStationComponent::update()
|
||||
@@ -79,9 +80,16 @@ namespace BlackGui
|
||||
|
||||
void CAtcStationComponent::changedAtcStationsOnline()
|
||||
{
|
||||
// just update timestamp, data will be pulled by time
|
||||
// the timestamp will tell if there are newer data
|
||||
this->m_timestampOnlineStationsChanged = QDateTime::currentDateTimeUtc();
|
||||
}
|
||||
|
||||
void CAtcStationComponent::changedAtcStationOnlineConnectionStatus(const CAtcStation &station, bool added)
|
||||
{
|
||||
this->ui->tvp_AtcStationsOnline->changedAtcStationConnectionStatus(station, added);
|
||||
}
|
||||
|
||||
void CAtcStationComponent::changedAtcStationsBooked()
|
||||
{
|
||||
this->reloadAtcStationsBooked();
|
||||
|
||||
Reference in New Issue
Block a user