30486 Commits

Author SHA1 Message Date
Lorenzo Colitti
ba76f2ac2a am 6987036f: Merge "Make setupDataCall take a protocol parameter." into gingerbread
* commit '6987036fabbd2c0351986efcfd11e714ae75fdf8':
  Make setupDataCall take a protocol parameter.
2011-03-03 17:07:50 -08:00
Lorenzo Colitti
b028ce55ca Merge "Add a protocol property to the APNs and use it." into gingerbread 2011-03-03 17:04:07 -08:00
Lorenzo Colitti
6987036fab Merge "Make setupDataCall take a protocol parameter." into gingerbread 2011-03-03 17:03:58 -08:00
Jeff Brown
9503e8bc17 am e23c235c: Merge "Only set KeyEvent long press flag when repeat count equals 1." into gingerbread
* commit 'e23c235c662c3028cfb080c6ed60d7defcdd0b69':
  Only set KeyEvent long press flag when repeat count equals 1.
2011-03-03 15:03:26 -08:00
Jeff Brown
e23c235c66 Merge "Only set KeyEvent long press flag when repeat count equals 1." into gingerbread 2011-03-03 14:42:14 -08:00
Jozef BABJAK
17eb45fff8 Lazy initialization must be synchronized to avoid parallel instances cretation.
Change-Id: I9c6887c714f42534a465c266689dc03ee7298900
2011-03-03 10:22:12 +01:00
Jozef BABJAK
0dbe721d0a Fixing improper boxing to Integer instead of Long.
This is tricky: entry.getMessageBox() returns int, so it is
by default boxed to Integer. Map.get() however accepts Objects,
so it ignores the difference, but nothing is find during lookup,
just because Long and Integer objects are compared using equals(),
which has to lead to 'false' result. So, explicit boxning to Long
is unnecessary here.

Change-Id: I967a7829a8926410a00274c6b5e312e1af567299
2011-03-03 10:09:53 +01:00
Mike Lockwood
d948b85dc9 am 611af238: DO NOT MERGE: UsbManager: Don\'t display activity picker if there are no apps available for an accessory
* commit '611af238185cf924a425a1a2154b8439b8f8d7a5':
  DO NOT MERGE: UsbManager: Don't display activity picker if there are no apps available for an accessory
2011-03-02 22:07:59 -08:00
Mike Lockwood
611af23818 DO NOT MERGE: UsbManager: Don't display activity picker if there are no apps available for an accessory
Change-Id: I1aa578887e42aef375211eadece4c1fddaf234f8
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-02 22:00:59 -08:00
Jeff Brown
59fd13c7be Only set KeyEvent long press flag when repeat count equals 1.
This fixes a Gingerbread regression.

Bug: 3507021
Change-Id: Ia6030665b6a406332adc0ee0d8ee3cb735338c8e
2011-03-02 20:49:06 -08:00
Mike Lockwood
e91e5f6e9d am c9ac3f51: Merge "DO NOT MERGE: UsbService: Make sure the USB accessory function is disabled when we disconnect" into gingerbread
* commit 'c9ac3f5183be3f124f34ed49ac5766e0ba1aff77':
  DO NOT MERGE: UsbService: Make sure the USB accessory function is disabled when we disconnect
2011-03-02 18:32:08 -08:00
Mike Lockwood
c9ac3f5183 Merge "DO NOT MERGE: UsbService: Make sure the USB accessory function is disabled when we disconnect" into gingerbread 2011-03-02 18:27:33 -08:00
Mike Lockwood
ae0fdf13e2 DO NOT MERGE: UsbService: Make sure the USB accessory function is disabled when we disconnect
BUG: 3493041

Change-Id: I6aeb00a1d91d98a5a0aef4ed97ca5ba68daa24be
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-02 18:24:59 -08:00
Simon Wilson
3d79f1ce84 am edc68a00: Merge "Attempt to reduce problems from issue #3183612" into gingerbread
* commit 'edc68a001cd94d2011029004cb27231432a18575':
  Attempt to reduce problems from issue #3183612
2011-03-02 18:10:33 -08:00
Simon Wilson
edc68a001c Merge "Attempt to reduce problems from issue #3183612" into gingerbread 2011-03-02 18:03:52 -08:00
Mike Lockwood
b13581a9da am 1110748b: DO NOT MERGE: USB accessory support library
* commit '1110748b2df664f9c5066819c1f0616eae3394a7':
  DO NOT MERGE: USB accessory support library
2011-03-02 15:38:55 -08:00
Mike Lockwood
1110748b2d DO NOT MERGE: USB accessory support library
This provides a mechanism for developing applications to work with
USB accessories in versions of android prior to the introduction
of the android.hardware.UsbManager APIs.

Applications should link against the com.android.future.usb.accessory
library to use this support.

Change-Id: I0b61e20b63eec42c506f0895a0c9a439bdfdf7f5
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-02 15:23:41 -08:00
Mike Lockwood
7866be2b76 am 40bbf929: DO NOT MERGE: Backport USB accessory support to gingerbread
* commit '40bbf9295d5245d3917629ce15f7b37670aef1ac':
  DO NOT MERGE: Backport USB accessory support to gingerbread
2011-03-02 15:16:32 -08:00
Mike Lockwood
40bbf9295d DO NOT MERGE: Backport USB accessory support to gingerbread
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-01 23:09:12 -08:00
Costin Manolache
66d46ac614 am db52ab69: Merge "DO NOT MERGE Backport (with modifications ) some changes from Honeycomb, that would allow authenticators to control caching and permissions." into gingerbread
* commit 'db52ab69f22e24615eaa2e8f9845e157426d3dd6':
  DO NOT MERGE Backport (with modifications ) some changes from Honeycomb, that would allow authenticators to control caching and permissions.
2011-03-01 12:29:40 -08:00
Costin Manolache
db52ab69f2 Merge "DO NOT MERGE Backport (with modifications ) some changes from Honeycomb, that would allow authenticators to control caching and permissions." into gingerbread 2011-03-01 12:25:21 -08:00
Costin Manolache
ef419b2e14 DO NOT MERGE
Backport (with modifications ) some changes from Honeycomb, that would allow authenticators to control caching and permissions.

This is backward compatible - both new and old authenticators will work with old and new framework,
but the functionality will only be present if both sides support it.

Change-Id: Ib2838cc2159f45264b38c844cd4c1d6f315d8064
2011-03-01 11:20:06 -08:00
Dianne Hackborn
7fff2d19a2 am 1de4a2ca: am 62619392: Merge "Fix leak when keylock is recreated."
* commit '1de4a2ca58df9bd21e054742f52e0af7a2ed5864':
  Fix leak when keylock is recreated.
2011-02-28 18:06:46 -08:00
Dianne Hackborn
1de4a2ca58 am 62619392: Merge "Fix leak when keylock is recreated."
* commit '626193926df0b3c7236e5c244f30d797d9192e0d':
  Fix leak when keylock is recreated.
2011-02-28 18:03:12 -08:00
Dianne Hackborn
626193926d Merge "Fix leak when keylock is recreated." 2011-02-28 17:54:54 -08:00
Jaikumar Ganesh
516393faba am 9711b9b7: am 1eefb529: Merge "Phone crash when old callback func is woken up when enabling BT."
* commit '9711b9b7aa7448b44b85fe8158ded0364cc3540e':
  Phone crash when old callback func is woken up when enabling BT.
2011-02-28 16:27:16 -08:00
Jaikumar Ganesh
9711b9b7aa am 1eefb529: Merge "Phone crash when old callback func is woken up when enabling BT."
* commit '1eefb529c78be5336f6c8a1b8ac2c32e268d4294':
  Phone crash when old callback func is woken up when enabling BT.
2011-02-28 16:00:01 -08:00
Jaikumar Ganesh
1eefb529c7 Merge "Phone crash when old callback func is woken up when enabling BT." 2011-02-28 15:33:34 -08:00
Mike Lockwood
c01e201f12 am 61c1bb4f: Merge "UsbService: Remove stack-trace message during boot. DO NOT MERGE" into gingerbread
* commit '61c1bb4fef439650a3b88131c6e1360ffc03a7ed':
  UsbService: Remove stack-trace message during boot. DO NOT MERGE
2011-02-28 13:18:06 -08:00
Mike Lockwood
fc88f94fc3 am 6da062a9: Merge "DO NOT MERGE: Clean up USB notifications:" into gingerbread
* commit '6da062a96c6f8126aad450a937144fab4333488f':
  DO NOT MERGE: Clean up USB notifications:
2011-02-28 13:18:02 -08:00
Mike Lockwood
54e96c69d0 am 3333f8af: Merge "DO NOT MERGE UsbManager: squashed commit of:" into gingerbread
* commit '3333f8afb2d1eae8bfdb41fa87f86836ad8702f7':
  DO NOT MERGE UsbManager: squashed commit of:
2011-02-28 13:17:58 -08:00
Mike Lockwood
f41768c583 am f7b99b32: Merge "Give system server permission to access USB. DO NOT MERGE" into gingerbread
* commit 'f7b99b32ad7a4872376355acabb5984142ba5e75':
  Give system server permission to access USB. DO NOT MERGE
2011-02-28 13:17:54 -08:00
Mike Lockwood
61c1bb4fef Merge "UsbService: Remove stack-trace message during boot. DO NOT MERGE" into gingerbread 2011-02-28 13:12:11 -08:00
Mike Lockwood
6da062a96c Merge "DO NOT MERGE: Clean up USB notifications:" into gingerbread 2011-02-28 13:12:03 -08:00
Mike Lockwood
3333f8afb2 Merge "DO NOT MERGE UsbManager: squashed commit of:" into gingerbread 2011-02-28 13:11:55 -08:00
Mike Lockwood
f7b99b32ad Merge "Give system server permission to access USB. DO NOT MERGE" into gingerbread 2011-02-28 13:11:37 -08:00
Xavier Ducrohet
7b9727558b am edbd6139: Merge "Merge 1911a6f7 into gingerbread. do not merge." into gingerbread
* commit 'edbd6139b9d699879db2f14fb03b7b6a38bab9ea':
  Merge 1911a6f7 into gingerbread. do not merge.
2011-02-28 12:29:08 -08:00
Xavier Ducrohet
edbd6139b9 Merge "Merge 1911a6f7 into gingerbread. do not merge." into gingerbread 2011-02-28 12:24:01 -08:00
Lorenzo Colitti
3c4e929cfd Add a protocol property to the APNs and use it.
1. Database changes:
   - Add a protocol and a roaming_protocol column to the
     carriers table in the telephony provider database.
   - Set the protocol and roaming_protocol fields when
     creating APN objects from the database.

2. ApnSetting class changes:
   - Add protocol and roamingProtocol fields to the
     ApnSetting class that encapsulates APN settings within
     the framework.
   - Add the fields to ApnSetting.toString and support a new
     syntax containing the fields in ApnSetting.fromString.
   - Add a unit test for ApnSetting.

3. Telephony changes:
   - Specify the APN protocol when setting up a data call,
     using protocol when not roaming and roaming_protocol
     when roaming.

This change depends on #86896 in the telephony provider,
which adds the new column to the database schema on
upgrades.

Bug: 3333633
Change-Id: If3d9ed4c851d0192849df0d64581db03b066e052
2011-02-28 11:17:05 -08:00
Lorenzo Colitti
93faa3239e Make setupDataCall take a protocol parameter.
Backport the protocol changes to setupDataCall and its
callers from master. As in master, hardcode IPv4
connectivity for now. When we add the protocol field to
ApnSettings, it will be fetched from there.

Bug: 3333633
Change-Id: I51880bc0ec192cbf964ac7bbd6a4b7d2eed41d27
2011-02-28 11:16:57 -08:00
Jean-Baptiste Queru
79b66725b7 am 25be2c72: am e0537f18: Merge "Fix of tearDown() in SingleLaunchActivityTestCase."
* commit '25be2c725eba1c94c7fc700e37b194fdcd83a1fb':
  Fix of tearDown() in SingleLaunchActivityTestCase.
2011-02-28 10:18:30 -08:00
Jean-Baptiste Queru
25be2c725e am e0537f18: Merge "Fix of tearDown() in SingleLaunchActivityTestCase."
* commit 'e0537f1859664ba9c9cf87eb9d6dc3c16986dbb8':
  Fix of tearDown() in SingleLaunchActivityTestCase.
2011-02-28 10:15:46 -08:00
Jean-Baptiste Queru
e0537f1859 Merge "Fix of tearDown() in SingleLaunchActivityTestCase." 2011-02-28 10:12:08 -08:00
Xavier Ducrohet
ce57a7f353 am 6504490c: am dff6b8e7: Merge "Add --non-constant-id to aapt."
* commit '6504490cde3ec5d48321d539e654d1f2072b33f9':
  GpsLocationProvider: Clean up HAL initialization/cleanup sequence
  Fixed GSM encoded network initiated position request
  Ensuring thread-safe usage of DateFormat.
  Fixing infinite loop for zero duration.
  Fix for an infinite loop while scrolling lists.
  WAPPushManager, WAP Push over SMS message handler
  Add --non-constant-id to aapt.
2011-02-28 09:51:38 -08:00
Xavier Ducrohet
6504490cde am dff6b8e7: Merge "Add --non-constant-id to aapt."
* commit 'dff6b8e71dda9f5d841fa26408714aec2aef1505':
  GpsLocationProvider: Clean up HAL initialization/cleanup sequence
  Fixed GSM encoded network initiated position request
  Ensuring thread-safe usage of DateFormat.
  Fixing infinite loop for zero duration.
  Fix for an infinite loop while scrolling lists.
  WAPPushManager, WAP Push over SMS message handler
  Add --non-constant-id to aapt.
2011-02-28 09:16:38 -08:00
Kenneth Andersson
1e0c7ae184 Fix leak when keylock is recreated.
DigitalClock could sometimes leak when the keylock was recreated.
This happened because onDetachedFromWindow() was called BEFORE
onAttachedFromWindow().
This is the flow that causes the memory leak:
1) The LockPatternKeyGuardView is created and added. This will start
a loop dispatching onAttachedToWindow() to all views involved.
2) PatternUnlockScreen.onAttachedToWindow() is called
3) If the configuration has changed since creation, recreateMe() in
LockPatternKeyguardView.java is called.
4) recreateScreens() is called
5) PatternUnlockScreen is removed (to be re-added later) in
LockPatternKeyguardView.recreateUnlockScreen()
6) Since DigitalClock is a part of PatternUnlockScreen, its
onDetachedFromWindow() will be called.
7) The loop started in 1) will continue to dispatch
onAttachedToWindow() - and will eventually call
DigitalClock.onAttachedToWindow()
8) DigitalClock.onAttachedToWindow() registers a receiver that is
normally unregistered in onDetachedFromWindow(). But since
onDetachedFromWindow was already called in 6), it will not be called
again.
9) The receiver has leaked, and it has a reference to DigitalClock,
so that will leak as well, together with its parents e.g.
PatternUnlockScreen and LockPatternKeyguardView

The fix is to wait with the recreation of the screens (in 4) until
the loop (in 1) is finished. This is done by posting this as an event
instead of calling recreateScreens() immediately.

It is possible that this a fix for the root cause mentioned in
"Fix 3106227: use WeakReferences for receivers in DigitalClock class"
8b886fab5496b0b1f5193f21855220176deddc37 by Jim Miller
<jaggies@google.com>.

Change-Id: I6a5f6f49a565d459bf4e285f34f053cc1022286f
2011-02-28 14:09:08 +01:00
David 'Digit' Turner
1a7408cd64 UsbService: Remove stack-trace message during boot. DO NOT MERGE
This removes a stack trace message during the boot under emulation.

The observers tried to access a null reference when no USB configuration
is supported by the emulated device. So do not start them in this case.

+ Change a Slog.w into a Slog.i since this is an acceptable condition.

Change-Id: I801f352574716d7868f182bb6e5ee49e5b12e4f1
2011-02-27 18:39:41 -08:00
Mike Lockwood
f13ec7a3ac DO NOT MERGE: Clean up USB notifications:
Add support for separate USB connected and configuration events

Include both USB connected/disconnected and configuration state
in USB_STATE Intent

Remove redundant USB_CONNECTED and USB_DISCONNECTED Intents
Now we just have the sticky USB_STATE broadcast

Move USB disconnnect rebouncing from Tethering to UsbService

Change-Id: I1dea480f4b0daf14247cf37c5f2060498882c002
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-27 18:39:26 -08:00
Mike Lockwood
7916432b3c DO NOT MERGE UsbManager: squashed commit of:
USB: Add functions for querying if a USB function is supported and enabled.

Rename android.hardware.Usb to UsbManager and UsbObserver to UsbService

Change-Id: I920a211934d993eab8ce744c1cc7b05342389286
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-27 18:39:21 -08:00
Mike Lockwood
89e7f9fd70 Give system server permission to access USB. DO NOT MERGE
Change-Id: I8d64bcaf2483eaa8690aef7ee2d1bb8ed9453fbe
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-27 17:50:59 -08:00