Fix crash if gc configured but adapter not connected

This commit is contained in:
Ameer 2020-07-14 11:23:10 -04:00
parent 393cdb15f5
commit ab65de2f96
2 changed files with 25 additions and 15 deletions

View file

@ -100,6 +100,9 @@ public:
void BeginConfiguration();
void EndConfiguration();
/// Returns true if there is a device connected to port
bool DeviceConnected(std::size_t port);
std::array<Common::SPSCQueue<GCPadStatus>, 4>& GetPadQueue();
const std::array<Common::SPSCQueue<GCPadStatus>, 4>& GetPadQueue() const;
@ -119,9 +122,6 @@ private:
/// Stop scanning for the adapter
void StopScanThread();
/// Returns true if there is a device connected to port
bool DeviceConnected(std::size_t port);
/// Resets status of device connected to port
void ResetDeviceType(std::size_t port);