Bluetooth: Update the Bluetooth state in STOP_TIMEOUT case

Bluetooth adapter state is getting updated with turn off
but the same intent is not getting broad casted to the
application, so it hanged in turning off state.

Broadcasting the TRUN_OFF intent in STOP_TIMEOUT case.

CRs-fixed: 534372
Change-Id: I4f05a946e56a87ff62c6e505b6bfbfbfe7c8c951
PBAP: Strip unwanted braces from telephone number.

This patch removes unwanted spaces from the telephone
number on vcard entry formation. Handsfree call
was failing because of these characters due to
different BTIF handling in Bluedroid.

Change-Id: I2d63967059a9cb97f214b370fac17234f6e58f55
CRs-fixed: 533935
Bluetooth: Retry pairing attempt again for pagetimeout

This is to add logic to retry pairing if it fails due to page timeout
or remote down. This allows to avoid lots of pairing failures if DUT
tries pairing when remote is trying to connect to previously connected
device.

Change-Id: Ic456406704846816c062923f8782b55e9fa1b96f
CRs-Fixed: 545387
Revert "Bluetooth: Connect only A2dp Sink devices."

Some devices support A2dp sink but they have not set
rendering bit in COD.Instead of COD use UUID to connect
A2dp sink devices.
This reverts commit 661d7e5637665c0d9d0bae6286dccb29914b8fc7.

Change-Id: Iba07b811ca859642c3cb75ed490f71f050811ad4
Properly update profile connection state.

When DUT is toggled between various paired Headsets Connection
state is not updated properly in some scenarios.This is causing
Bluetooth icon to be in connected state even when no Headsets are
connected.Also make sure connected,connecting,disconnecting devices
count is never negative.

Change-Id: Icb1a7215ff6d9491afbb5f7f203ca0a2c6b7f43a
CRs-Fixed: 532783
Merge "Revert "Bluetooth: Connect only A2dp Sink devices.""
Bluetooth:Handling Connect request in AudioOn state.

While in active call, connected to the first BT HS, when we
initiate connection to a second BT HS, connection was not
happening because of which the call audio was routing to the
speaker. Added Connect message handling in the AudioOn state.

Change-Id: I3d9f4265aa2cfddf141ac60f7da82fabfd4bc383
CRs-Fixed: 534731
Bluetooth: Fix strings.xml after CAF merge [translation]

Change-Id: I087253df8bb08b0404dd2633fdf581e52ad1dff6
Bluetooth: Fix aapt string warnings [translation]

Change-Id: I74dc8b3dac031243c6c88bf256a22c3b22a1b78d
Merge "PBAP: Strip unwanted braces from telephone number."
Merge "Properly update profile connection state."
Bluetooth: NL translations

Change-Id: I19191bd9e9efb245b40395d14ab4655affecf370
Bluetooth: ES translations

Change-Id: If03536cba1b234f7e8b009f6063f026b55734da4
Merge "Bluetooth: Retry pairing attempt again for pagetimeout"
Check for A2DP UUIDs supported by remote device

Before sending connect request for A2dp check for roles
supported by remote device and proceed accordingly.

Change-Id: I0200582a69b3d4e9b7f92516ba92f34054a1f4dc
CRs-Fixed: 507306
Merge "Bluetooth: ES translations" into cm-10.2
Bluetooth:Send Connection request after Connection Failure.

When one of profile is un-checked from setting sub-menu and initial
connection has failed then try to re-connect selected profile.

Change-Id: I67bf658b5b9ce556fc0d54030989e6033651051b
CRs-Fixed: 543050
Update UI properly in Connection race Conditions.

Broadcast connection state of incoming device in pending
state and update UI for disconnection of outgoing connection.

Change-Id: Ibd80fc7010613887df74fb1903b16de73c77939a
CRs-Fixed: 531637
Bluetooth: HU translation

Change-Id: I7047d7ef90526f5712e6a6acbedb288e88023da5
Bluetooth: CA translations

Change-Id: Ife5c05bb12787cfe8c024fea778cb24afc10be41