Commit 3b8a69ad authored by Don Gagne's avatar Don Gagne

Update android build to LinkReference changes

parent fd6a2f90
......@@ -29,24 +29,20 @@
#include "BluetoothLink.h"
#include "QGC.h"
BluetoothLink::BluetoothLink(BluetoothConfiguration* config)
: _connectState(false)
BluetoothLink::BluetoothLink(SharedLinkConfigurationPointer& config)
: LinkInterface(config)
, _connectState(false)
, _targetSocket(NULL)
#ifdef __ios__
, _discoveryAgent(NULL)
#endif
, _shutDown(false)
{
Q_ASSERT(config != NULL);
_config = config;
_config->setLink(this);
//moveToThread(this);
}
BluetoothLink::~BluetoothLink()
{
// Disconnect link from configuration
_config->setLink(NULL);
_disconnect();
#ifdef __ios__
if(_discoveryAgent) {
......
......@@ -169,7 +169,7 @@ protected:
private:
// Links are only created/destroyed by LinkManager so constructor/destructor is not public
BluetoothLink(BluetoothConfiguration* config);
BluetoothLink(SharedLinkConfigurationPointer& config);
~BluetoothLink();
// From LinkInterface
......
......@@ -493,7 +493,7 @@ void LinkManager::_updateAutoConnectLinks(void)
// Android builds only support a single serial connection. Repeatedly calling availablePorts after that one serial
// port is connected leaks file handles due to a bug somewhere in android serial code. In order to work around that
// bug after we connect the first serial port we stop probing for additional ports.
if (!_autoconnectConfigurations.count()) {
if (!_sharedAutoconnectConfigurations.count()) {
portList = QGCSerialPortInfo::availablePorts();
}
#else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment