Commit Graph

988 Commits

Author SHA1 Message Date
Amith Yamasani
290ba7c1ae Fix NPE in BT Settings launch from a shortcut.
Bug: 3089335
2010-10-13 13:33:32 -07:00
Jaikumar Ganesh
836b4297cc am 03403712: Merge "DO NOT MERGE Add null check before disconnecting a device." into gingerbread
Merge commit '0340371297887290d7593d7c346e422a4c9ecd1a' into gingerbread-plus-aosp

* commit '0340371297887290d7593d7c346e422a4c9ecd1a':
  DO NOT MERGE Add null check before disconnecting a device.
2010-10-13 11:13:33 -07:00
Jaikumar Ganesh
268d1f1e4b DO NOT MERGE Add null check before disconnecting a device.
Bug: 3076404
Change-Id: I8ef140395503816296124a38e42ab9cc7e6f7159
2010-10-13 10:56:01 -07:00
Jaikumar Ganesh
0d5e320cdd am bdf13107: Merge "Call disconnect / connect without checking the current status" into gingerbread
Merge commit 'bdf1310707e436db484113d7aa2881c966cddd0f' into gingerbread-plus-aosp

* commit 'bdf1310707e436db484113d7aa2881c966cddd0f':
  Call disconnect / connect without checking the current status
2010-10-12 19:06:15 -07:00
Jaikumar Ganesh
d3a460cce7 Call disconnect / connect without checking the current status
Its the job of the framework to check that, it already does that.
Framework will queue the commands. Earlier settings app used to queue
them.

Bug: 3076404

Change-Id: I664e1c4e2c0ef9c697066251ccca382ad12dfa2f
2010-10-12 16:19:40 -07:00
Jake Hamby
4747950d8e am d7f7213a: am 4c0ff2c7: Merge "Fix bug where car dock sometimes doesn\'t connect." into gingerbread
Merge commit 'd7f7213af27fa6c5e476bb8a8d2951feb5e630b5'

* commit 'd7f7213af27fa6c5e476bb8a8d2951feb5e630b5':
  Fix bug where car dock sometimes doesn't connect.
2010-10-12 13:18:21 -07:00
Jake Hamby
d7f7213af2 am 4c0ff2c7: Merge "Fix bug where car dock sometimes doesn\'t connect." into gingerbread
Merge commit '4c0ff2c7b5138c0fce6c83f6c414204e32ac96f3' into gingerbread-plus-aosp

* commit '4c0ff2c7b5138c0fce6c83f6c414204e32ac96f3':
  Fix bug where car dock sometimes doesn't connect.
2010-10-11 13:07:09 -07:00
Jake Hamby
582f1f84bb Fix bug where car dock sometimes doesn't connect.
Attempt to connect to car/desk dock after pairing completes. This
fixes a bug where we didn't try to connect if we received the UUID
change intent before the bonding state change intent.

Change-Id: I7c12a4eb23d17d506e43a64bf2a3aa5241debcb9
2010-09-29 15:38:19 -07:00
Jaikumar Ganesh
5809d33296 Update code for public Bluetooth APIs
Change-Id: Iab22e4ae3206f9085b2d53b8b18dc2abd6197226
2010-09-28 17:53:02 -07:00
Jake Hamby
989408cc70 am 68c6188b: am dd79a33b: Auto-connect Bluetooth device only when user initiates pairing.
Merge commit '68c6188b91ca4034caeff7527487513c8cb012f8'

* commit '68c6188b91ca4034caeff7527487513c8cb012f8':
  Auto-connect Bluetooth device only when user initiates pairing.
2010-09-24 17:19:24 -07:00
Jake Hamby
68c6188b91 am dd79a33b: Auto-connect Bluetooth device only when user initiates pairing.
Merge commit 'dd79a33ba53fec530094f4d2fe37f0538530d9f8' into gingerbread-plus-aosp

* commit 'dd79a33ba53fec530094f4d2fe37f0538530d9f8':
  Auto-connect Bluetooth device only when user initiates pairing.
2010-09-24 17:16:37 -07:00
Jake Hamby
dd79a33ba5 Auto-connect Bluetooth device only when user initiates pairing.
Fix bug 2271901: do not auto-connect to services on a BT device
when pairing was initiated by the device (e.g. for OPP file transfer).

Also corrected some typos and removed an unneeded lock object in
LocalBluetoothManager (synchronize on .class object instead, like
android.bluetooth.BluetoothDevice.getService() does).

Change-Id: I121105c6eee2658129f6094786754bbc7932d324
2010-09-24 14:23:26 -07:00
Jake Hamby
2695660674 am 5496db04: am 59091c08: Fix Bluetooth device name max length checking.
Merge commit '5496db047df21a44280c56984dbc296e2a1d7968'

* commit '5496db047df21a44280c56984dbc296e2a1d7968':
  Fix Bluetooth device name max length checking.
2010-09-22 17:05:30 -07:00
Jake Hamby
5496db047d am 59091c08: Fix Bluetooth device name max length checking.
Merge commit '59091c08f4d0ad8f42013f58ce9bd23ac3306336' into gingerbread-plus-aosp

* commit '59091c08f4d0ad8f42013f58ce9bd23ac3306336':
  Fix Bluetooth device name max length checking.
2010-09-22 16:26:02 -07:00
Jake Hamby
59091c08f4 Fix Bluetooth device name max length checking.
The Bluetooth device name has a maximum length of 248 bytes in UTF-8
encoding. The settings app previously limited the Bluetooth device
name entered by the user based on the number of characters, which is
incorrect when the name includes non-ASCII characters.

Created a new Utf8ByteLengthFilter class for BluetoothNamePreference
which counts UTF-8 bytes instead of Unicode characters, along with
unit tests.

We can move Utf8ByteLengthFilter into the framework in the future
if it would be useful elsewhere in the system or for applications.

Change-Id: I9debface09659f09d750f3bfe8ad6ddfd34c75c5
2010-09-22 16:04:50 -07:00
Jaikumar Ganesh
69b0218849 am 356745ec: am 213d579f: Merge "Don\'t disconnect the same device before connecting." into gingerbread
Merge commit '356745ecc63419a2569345186e8612a5b0ced28d'

* commit '356745ecc63419a2569345186e8612a5b0ced28d':
  Don't disconnect the same device before connecting.
2010-09-16 23:24:15 -07:00
Jaikumar Ganesh
356745ecc6 am 213d579f: Merge "Don\'t disconnect the same device before connecting." into gingerbread
Merge commit '213d579f98a83145989f11cfdbd47631b64de000' into gingerbread-plus-aosp

* commit '213d579f98a83145989f11cfdbd47631b64de000':
  Don't disconnect the same device before connecting.
2010-09-16 22:15:50 -07:00
Jaikumar Ganesh
213d579f98 Merge "Don't disconnect the same device before connecting." into gingerbread 2010-09-16 19:08:32 -07:00
Jaikumar Ganesh
84905edb63 Don't disconnect the same device before connecting.
We Pair: Remote device sends incoming connection, we get connected.
We get BondingState change and we connect.
Settings app disconnects connected profiles and then connects
without checking whether we are disconnecting the same device itself.

How was it working before ? Settings app used to queue all
commands. The disconnect followed by the connect would work
but unnecessarily disconnect and then connect.
With the queuing moved to framework, the connect fails
since the disconnect status has not been broadcasted.

Settings app shouldn't be disconnecting connected profiles.
That logic should reside in the framework. There is an open bug
and when the new APIs get implemented this will get removed.

Change-Id: I32a7fa36ff3c3321691c55071498f985dcdcfe8e
2010-09-16 18:56:30 -07:00
Brad Fitzpatrick
eaea841be0 am f8a473c3: am c5c8dad0: Use new apply() instead of commit().
Merge commit 'f8a473c3985d7c818dc24f94330f210e1d56a409'

* commit 'f8a473c3985d7c818dc24f94330f210e1d56a409':
  Use new apply() instead of commit().
2010-09-15 07:08:52 -07:00
Brad Fitzpatrick
f8a473c398 am c5c8dad0: Use new apply() instead of commit().
Merge commit 'c5c8dad0afb84bda9495a0aa1f7d6a3db28de5cb' into gingerbread-plus-aosp

* commit 'c5c8dad0afb84bda9495a0aa1f7d6a3db28de5cb':
  Use new apply() instead of commit().
2010-09-14 10:29:35 -07:00
Brad Fitzpatrick
c5c8dad0af Use new apply() instead of commit().
apply() starts an async disk write and doesn't have a return
value but is otherwise identical in observable effects.

Change-Id: I0f528607319d7eb5136bb11fce0b24d8741ccdf9
2010-09-14 09:26:51 -07:00
Daisuke Miyakawa
6ebf8619d7 Fragmentize BluetoothSettings.
Add UserLeaveHintListener.java, so that the settings won't use
its implementation around Activity#onUserLeaveHint().

Also fragmentize bluetooth tethering screen.

Change-Id: Id06ae3161fbdb5854ddb7a257f464fb16ea9b089
2010-09-13 16:18:05 -07:00
Jaikumar Ganesh
470ae03ec1 am 1647d472: am e714898a: Merge "OutOfband pairing user dialog." into gingerbread
Merge commit '1647d472a8c04069a0aab22730a54ec374185ea5'

* commit '1647d472a8c04069a0aab22730a54ec374185ea5':
  OutOfband pairing user dialog.
2010-09-13 14:42:36 -07:00
Jaikumar Ganesh
1647d472a8 am e714898a: Merge "OutOfband pairing user dialog." into gingerbread
Merge commit 'e714898a1abfd828a239e1be7b3f75e2a3cc2120' into gingerbread-plus-aosp

* commit 'e714898a1abfd828a239e1be7b3f75e2a3cc2120':
  OutOfband pairing user dialog.
2010-09-13 11:52:15 -07:00
Jaikumar Ganesh
a197eea307 OutOfband pairing user dialog.
Change-Id: I2f996067b983ad4678814040eb0773fa3968be13
2010-09-09 15:29:03 -07:00
Erik Ljungberg
df4a5b3ada am 6e6d0580: am 83c3b64f: BT: The Phone doesn\'t "wake up" when trying to pair with it.
Merge commit '6e6d05801e68e8d2cee2c708274dc8226f04f756'

* commit '6e6d05801e68e8d2cee2c708274dc8226f04f756':
  BT: The Phone doesn't "wake up" when trying to pair with it.
2010-09-01 22:07:22 -07:00
Erik Ljungberg
6e6d05801e am 83c3b64f: BT: The Phone doesn\'t "wake up" when trying to pair with it.
Merge commit '83c3b64ff7235e1382712a899ab0a269ce8a28d6' into gingerbread-plus-aosp

* commit '83c3b64ff7235e1382712a899ab0a269ce8a28d6':
  BT: The Phone doesn't "wake up" when trying to pair with it.
2010-09-01 22:04:59 -07:00
Erik Ljungberg
83c3b64ff7 BT: The Phone doesn't "wake up" when trying to pair with it.
To improve the pairing request usability:
- In the case where a notification shall be used the standard
  notification sound is added
- When the screen is off notification is always used.

Change-Id: I751a7913517c64de5d7ba06d7c17358197d002c5
2010-09-01 21:59:48 -07:00
Jaikumar Ganesh
8eb4986049 Match devices by Class for tethering.
Change-Id: I711de3c8d6f6b1dafeec4fb5dde4fa33d997bcca
2010-08-23 11:49:19 -07:00
Jake Hamby
2cd6aad561 am 2876ad62: am 2fcfb289: Merge " Fix Bluetooth Settings activity memory leak."
Merge commit '2876ad62082207e0e02cbc38b65ce9993cb121bf'

* commit '2876ad62082207e0e02cbc38b65ce9993cb121bf':
  Fix Bluetooth Settings activity memory leak.
2010-08-21 09:35:49 -07:00
Jake Hamby
2876ad6208 am 2fcfb289: Merge " Fix Bluetooth Settings activity memory leak."
Merge commit '2fcfb28982b84a6383774cfd50d6a963b1a985e1' into gingerbread-plus-aosp

* commit '2fcfb28982b84a6383774cfd50d6a963b1a985e1':
  Fix Bluetooth Settings activity memory leak.
2010-08-18 19:36:53 -07:00
Danica Chang
32711b6752 bluetooth tethering
Change-Id: I8dfb1c85bb8b963d2937b8bc4a4c9f0cf641785d
2010-08-17 19:07:07 -07:00
thigobr
d4cebee1e4 Fix Bluetooth Settings activity memory leak.
There were two leaks in Bluetooth Settings: one when rotating the
    phone and other when scanning for bluetooth devices.
2010-08-17 12:59:41 -03:00
The Android Open Source Project
e50496fb35 am be38a39f: merge from open-source master
Merge commit 'be38a39fc98d8574b747c57fea2aedd5d97fd333'

* commit 'be38a39fc98d8574b747c57fea2aedd5d97fd333':
  Fix window leak problems in settings.
2010-07-19 13:01:37 -07:00
The Android Open Source Project
be38a39fc9 merge from open-source master
Change-Id: Ibdfd887cae67bb6eba26e0f4e02765ad5b07e657
2010-07-19 12:52:09 -07:00
Jiehua.Dai
20108e2ed6 Fix window leak problems in settings.
There were window leak in the settings application.
These leak happens when an AlertDialog displays, rotate the phone,
then it would cause window leak.

Change-Id: I914897bf657933efea72eeea66076dc288098420
2010-07-14 11:10:00 +02:00
Adam Powell
792d2132e4 Add keyboard support to bluetooth settings.
Change-Id: I8fe41056acd074374cd249bfd0be6034f2614d37
2010-06-22 13:29:48 -07:00
Adam Powell
f907e0bb89 Fix bug 2713245 - Remove job queue from BT settings
Change-Id: I4e7269474cd270f22b16e9317e933ab87bff4929
2010-06-07 10:52:21 -07:00
Jaikumar Ganesh
8038834f8e Changing disconnectHeadset calls.
Change-Id: I2f058f28a09e983cd42e5a74bb4ffea19f07b880
2010-06-07 10:50:57 -07:00
Michael Chan
57d5585595 b/2680057 Fixed a bug where bt won't connect when the phone is docked (if Settings wasn't running).
The fix was to wait for the Bluetooth Headset service to come up before grabbing the settings and connecting.

Change-Id: I57affca2fe7d571c96cfeaf9ffe5439a0b02af45
2010-05-27 17:06:50 -07:00
Jaikumar Ganesh
d432bf76de Set profiles as preferred and then try to connect.
The APIs implementations are being updated to expose
A2DP and HFP APIs. A connect call is not honoured if its
not a preferred profile. So if an app changes the preference
of the profile than it should first update the state before
making the connect call. The API for updating preference
might not be exposed and will be mostly an API for app with ADMIN
privileges like Settings app.

Change-Id: I58b8e8201357bcfe615dc2322342520319d9e355
2010-05-24 18:00:56 -07:00
Michael Chan
d2c81986c2 b/2652059 Refresh UI after bond state change
Change-Id: I8f8a939ba3f383aae36091986cea4e8a6eae13fb
2010-05-07 15:24:22 -07:00
Michael Chan
1308453b16 b/2652059 Fixed the broken BT connects/disconnects after unpair
The unpair command was stuck in the queue.

Change-Id: I803cb10adcfaedbe6fd202e0db463593880e4280
2010-05-03 23:06:51 -07:00
Michael Chan
a0de1dcd19 b/2630339 Fixed the crash when an app requests BT to be enabled
For AlertActivity, the dialog needs to display at onCreate() time.
Otherwise, the decor view would be made. Trying to display the
dialog afterward would crash. Changed to AlertDialog instead.

Change-Id: I2ea8463b4c475b9b54746d0a722fa80eea3d4529
2010-04-28 11:24:00 -07:00
Michael Chan
96b0c1dc08 b/2608693 Fix the problem where BT was automatically reconnecting
... after the user unpaired while docked.

Change-Id: I65642f440109968387401fc3c103da0f2b15f49f
2010-04-22 16:07:35 -07:00
Michael Chan
293867bd10 b/2174155 Remove debug logging in bluetooth
Change-Id: Ia40af3bb362fe99fbfda1a23cdcb04fb96af7ca8
2010-04-07 13:31:21 -07:00
Michael Chan
d9db9e7621 Merge "b/2498180 b/2568119 Retry if BT dock disconnects unexpectedly" into froyo 2010-04-07 13:12:33 -07:00
Michael Chan
732c1dad5a b/2498180 b/2568119 Retry if BT dock disconnects unexpectedly
Change-Id: Ic4771e7c305192fee56f5f80c6cabeecf11a99dc
2010-04-06 15:42:04 -07:00
Adam Powell
54f334489c Fix bug 2564450 - prevent deadlock in BT settings
Change-Id: Iea5d341d771d18e5d9bf7c6686995ba6cbbf2172
2010-04-06 13:32:35 -07:00