mirror of
https://github.com/swift-project/pilotclient.git
synced 2026-04-14 08:45:36 +08:00
* added unload function to disconnect signals / slots and simulator * changed remote provider to return signal/slot connections to manually disconnect functor connects * flag so pause can freeze or continue AI aircraft * slightly changed unload behaviour in simulator context Remark: Tested for FSX only Solves #424 for FSX
This commit is contained in:
@@ -100,17 +100,14 @@ namespace BlackMisc
|
||||
virtual ~IRemoteAircraftProvider() {}
|
||||
|
||||
//! Connect signals to slot receiver. As the interface is no QObject, slots can not be connected directly.
|
||||
virtual bool connectRemoteAircraftProviderSignals(
|
||||
//! In order to disconnect a list of connections is provided, which have to be disconnected manually.
|
||||
//! \note connections are direct as functors have no parameter for connection type
|
||||
virtual QList<QMetaObject::Connection> connectRemoteAircraftProviderSignals(
|
||||
std::function<void(const BlackMisc::Aviation::CAircraftSituation &)> addedSituationSlot,
|
||||
std::function<void(const BlackMisc::Aviation::CAircraftParts &)> addedPartsSlot,
|
||||
std::function<void(const BlackMisc::Aviation::CCallsign &)> removedAircraftSlot,
|
||||
std::function<void(const BlackMisc::Simulation::CAirspaceAircraftSnapshot &)> aircraftSnapshot
|
||||
) = 0;
|
||||
|
||||
//! Disconnect signals from receiver. As the interface is no QObject, slots can not be connected directly.
|
||||
virtual bool disconnectRemoteAircraftProviderSignals(
|
||||
QObject *receiver
|
||||
) = 0;
|
||||
};
|
||||
|
||||
//! Class which can be directly used to access an \sa IRemoteAircraftProvider object
|
||||
|
||||
Reference in New Issue
Block a user