- I expected once Haiku sets a connection with a remote device, such connection

was to expire in a couple of minutes, but not, seems to stay forever.
- Implement a Disconnect button in prefrences&kit



git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@36450 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Oliver Ruiz Dorantes
2010-04-24 16:01:08 +00:00
parent 36cb67b24e
commit ddbc9a0f2a
6 changed files with 91 additions and 11 deletions
+4 -1
View File
@@ -6,6 +6,7 @@
#define _REMOTE_DEVICE_H
#include <bluetooth/bluetooth.h>
#include <bluetooth/bluetooth_error.h>
#include <bluetooth/BluetoothDevice.h>
#include <String.h>
@@ -36,7 +37,8 @@ public:
bool Equals(RemoteDevice* obj);
/*static RemoteDevice* GetRemoteDevice(Connection conn); Throwing */
bool Authenticate(); /* Throwing */
bool Authenticate(); /* Throwing */
status_t Disconnect(int8 reason = BT_REMOTE_USER_ENDED_CONNECTION);
/* bool Authorize(Connection conn); Throwing */
/*bool Encrypt(Connection conn, bool on); Throwing */
bool IsAuthenticated(); /* Throwing */
@@ -61,6 +63,7 @@ private:
LocalDevice* fDiscovererLocalDevice;
BMessenger* fMessenger;
uint16 fHandle;
uint8 fPageRepetitionMode;
uint8 fScanPeriodMode;
uint8 fScanMode;
+3 -3
View File
@@ -30,9 +30,9 @@
#define BT_HOST_TIMEOUT 0x10
#define BT_UNSUPPORTED_FEATURE 0x11
#define BT_INVALID_PARAMETERS 0x12
#define BT_OE_USER_ENDED_CONNECTION 0x13
#define BT_OE_LOW_RESOURCES 0x14
#define BT_OE_POWER_OFF 0x15
#define BT_REMOTE_USER_ENDED_CONNECTION 0x13
#define BT_REMOTE_LOW_RESOURCES 0x14
#define BT_REMOTE_POWER_OFF 0x15
#define BT_CONNECTION_TERMINATED 0x16
#define BT_REPEATED_ATTEMPTS 0x17
#define BT_PAIRING_NOT_ALLOWED 0x18