};
//DialogPage.ShowAlertDialog(Resources.IDS_BT_HEADER_DISCONNECT_DEVICE_ABB, String.Format(Resources.IDS_WMGR_POP_THIS_WILL_END_YOUR_CONNECTION_WITH_PS, btDevice.Name), cancelButton, disconnectButton);
- SettingCore.RoundedDialogPage.ShowAlertDialog("Disconnect device", String.Format("This will end your connection with { 0 }.", btDevice.Name), cancelButton, disconnectButton);
+ SettingCore.RoundedDialogPage.ShowAlertDialog("Disconnect device", String.Format("This will end your connection with {0}.", btDevice.Name), cancelButton, disconnectButton);
}
internal static void ConnectA2dp(BtDevice device)
mDeviceState = BtDeviceState.Paired;
BtModel.NotifyDeviceChanged(this);
//BtModel.NotifyOperationStateChanged(BtOperationState.Activated);
+ BtModel.NotifyOperationStateChanged(BtOperationState.Connecting);
if (mIsA2dpSupported)
{
Log.Info(SettingBluetooth.LogTag, "Automatically connect to the remote audio device after pairing");
mBluetoothAudio.Connect(BluetoothAudioProfileType.AdvancedAudioDistribution);
mDeviceState = BtDeviceState.Connecting;
BtModel.NotifyDeviceChanged(this);
- //BtModel.NotifyOperationStateChanged(BtOperationState.Connecting);
+ BtModel.NotifyOperationStateChanged(BtOperationState.Connecting);
}
catch (Exception e)
{
internal void RemoveFromPaired(BtDevice btDevice)
{
mPaired.RemoveDevice(btDevice);
+ mPaired.Clear();
if (mPaired.Count == 0)
{
this.Remove(mPaired);
case BtDeviceState.Unpaired:
if (mDeviceSource.FindInSearched(ev.BtDevice) == null)
{
- mDeviceSource.AddToSearched(ev.BtDevice); // TODO: need to add in front of the list
+ // TODO: need to add in front of the list
+ try
+ {
+ mDeviceSource.AddToSearched(ev.BtDevice);
+ }
+ catch (Exception e)
+ {
+ Log.Debug(SettingBluetooth.LogTag, "Exception : " + e.Message);
+ }
}
if (mDeviceSource.FindInPaired(ev.BtDevice) != null)
{