5296 Commits

Author SHA1 Message Date
Dianne Hackborn
6482517101 Fix issue #3485923: Gmail crash
Allow application to try to recover if a surface OOM error
happens on the client side.

Change-Id: I0308bd99647a35e4bcac448340b7fc6330a828f6
2011-03-02 22:38:58 -08:00
Dianne Hackborn
cbf9cb35bb Merge "Fix issue #3400119: API to specify a black background behind a window transition" 2011-03-02 17:19:39 -08:00
Dianne Hackborn
de75cb4738 Fix issue #3400119: API to specify a black background behind a window transition
There is now an API, which is used for task switching.

Also improved how we handle rotation animation when we can't take a
screen shot, to cleanly revert to the old freeze behavior.  This removes
the need to special case the emulator.

Change-Id: I7227432a2309370437ec6ac78db02c6f1e7eedd5
2011-03-02 17:15:58 -08:00
Jeff Brown
192f0b0608 Merge "Fade out the mouse pointer after inactivity or other events." 2011-03-02 15:54:42 -08:00
Jeff Brown
05dc66ada6 Fade out the mouse pointer after inactivity or other events.
Fades out the mouse pointer:
- after 15 seconds of inactivity normally
- after 3 seconds of inactivity in lights out mode
- after a non-modifier key down
- after a touch down

Extended the native Looper to support enqueuing time delayed
messages.  This is used by the PointerController to control
pointer fade timing.

Change-Id: I87792fea7dbe2d9376c78cf354fe3189a484d9da
2011-03-02 15:37:57 -08:00
Eric Laurent
1254169260 Merge "Fix issue 3388775." 2011-03-02 15:19:38 -08:00
Amith Yamasani
f867706180 am 0e99d3bf: am df33b8c5: Merge "Check for NTP time as soon as WIFI is connected." into honeycomb
* commit '0e99d3bfab99254cc187de127a7a4767f165cde8':
  Check for NTP time as soon as WIFI is connected.
2011-03-02 14:20:36 -08:00
Robert Greenwalt
7e48e76cab Merge "Start using NetworkUtils.numericToInetAddress." 2011-03-02 12:10:51 -08:00
Robert Greenwalt
e590373ea7 Start using NetworkUtils.numericToInetAddress.
Generates InetAddresses without risking an accidental dns lookup.  For use with supposedly
numeric-only ip address strings.

Change-Id: I694f3976ce1c6382854706f6557ea88a289add3a
2011-03-02 11:37:32 -08:00
Dianne Hackborn
0528bc7794 Merge "Fix issue #3431230: "am" debugging commands failing on -userdebug builds" 2011-03-02 10:19:12 -08:00
Kenny Root
3dee21eb0f Merge "Switch to returnCode for IPackageDeleteObserver" 2011-03-02 08:50:42 -08:00
Dianne Hackborn
f02e57bec0 Fix issue #3431230: "am" debugging commands failing on -userdebug builds
Change-Id: I6b5a8bf68d3bd76c7331ee97bab9a68b5033cb5a
2011-03-01 22:21:04 -08:00
Amith Yamasani
0e99d3bfab am df33b8c5: Merge "Check for NTP time as soon as WIFI is connected." into honeycomb
* commit 'df33b8c51d431a7c0f7a89ead8dfacdd3660ff48':
  Check for NTP time as soon as WIFI is connected.
2011-03-01 15:50:41 -08:00
Amith Yamasani
df33b8c51d Merge "Check for NTP time as soon as WIFI is connected." into honeycomb 2011-03-01 15:47:57 -08:00
Dianne Hackborn
fd938f323c Merge "Fix Issue 14340: Sticky Service killed with onDestroy not called, not restarted." 2011-03-01 14:36:12 -08:00
Amith Yamasani
8d394fa899 Check for NTP time as soon as WIFI is connected.
Listen for connectivity changes. If WIFI is connected, check if
we have recently checked for NTP time. If we haven't yet checked the
time or it has been long enough (a day), then connect to the NTP server
and get the latest time. Update the time if it is significantly out of sync.

This doesn't poll the NTP server every time there is connectivity, only
if it hasn't been checked since boot or has been a day.

This fixes the problem that during SetupWizard, we try to contact the NTP
server before there is connectivity and fail. Now, as soon as the user
chooses a WiFi network to connect to, it will update the time before
getting to the Date/Time step. Then as soon as the user corrects the TZ,
the date/time should be correct.

Bug: 3491920
Change-Id: I62664156616510b67ecd6a1c24dd838b98d5204f
2011-03-01 12:41:04 -08:00
Dianne Hackborn
3a28f22eb6 Fix Issue 14340: Sticky Service killed with onDestroy not called, not restarted.
Change-Id: I2804c49ad5669ca89744c6d92ead0c7d21ee31d5
http://code.google.com/p/android/issues/detail?id=14340
2011-03-01 12:25:54 -08:00
Mike Lockwood
6ebc6bde63 Merge "UsbDeviceSettingsManager: don't write settings file when not necessary" 2011-03-01 12:00:09 -08:00
Mike Lockwood
b4948d4d3f Merge "Fix UsbDeviceSettingsManager locking." 2011-03-01 11:59:32 -08:00
Mike Lockwood
04e1a9620f Merge "Move USB framework support from android.hardware to android.hardware.usb package" 2011-03-01 11:58:22 -08:00
Eric Laurent
42b3de5833 Merge "Fix issue 3479042." 2011-03-01 11:46:15 -08:00
Eric Laurent
bbc9fd3aca Fix issue 3388775.
Do not select A2DP output for media strategy when it is suspended because
BT SCO is active. Media audio will be routed to speakers or SCO HS
(depending on phone state and activity on stream VOICE_CALL) which is less
confusing than not hearing anything while music progress bar is moving.

Change-Id: Iff8cc1ea9bf9bde0b33035c4d91398db0934b836
2011-03-01 11:42:43 -08:00
Irfan Sheriff
2f6409686f Merge "Using AsyncChannel for wifi connectivity" 2011-03-01 11:32:24 -08:00
Mike Lockwood
31ad11eb44 UsbDeviceSettingsManager: don't write settings file when not necessary
Change-Id: I48772f71822e3489f9e6c640985055569a656124
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-01 11:03:19 -08:00
Mike Lockwood
7a976a4370 Fix UsbDeviceSettingsManager locking.
Change-Id: I93117ce791de95b0ab95017601f5d90ed5dd7a6a
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-01 09:40:07 -08:00
Kenny Root
c39bb4aaa7 Switch to returnCode for IPackageDeleteObserver
Before the IPackageDeleteObserver only knew whether the deletion
succeeded or failed, but not the reason why.

Bug: 2520191
Change-Id: I1f0d7c04f06c539660b6e17e7e133defb0f61b5b
2011-03-01 09:27:57 -08:00
Mike Lockwood
c4308f01c9 Move USB framework support from android.hardware to android.hardware.usb package
Change-Id: I00fd4f0caaa4aebe48f71c576bb211b5f38bf88d
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-01 08:07:20 -08:00
Mike Lockwood
c93f67c2b7 Merge "Add platform features for USB host and USB accessory support." 2011-02-28 17:05:12 -08:00
Mike Lockwood
fae640b174 Merge "UsbManager: Enhancements for managing USB devices and accessories" 2011-02-28 17:04:23 -08:00
Mike Lockwood
f4ca247158 Add platform features for USB host and USB accessory support.
Also removed config_hasUsbHostSupport framework resource, which is now obsolete.

Change-Id: I6f18cc1c4f68085de8b8363e1b5edff79aff404f
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-28 17:00:46 -08:00
Mike Lockwood
02eb8746de UsbManager: Enhancements for managing USB devices and accessories
When a USB device or accessory is connected, the UsbService now asks the
user which application to associate with the device or accessory.
Applications interested in devices or accessories must specify the
devices they work with via meta-data attached to their manifest.
Permission to communicate with the device is assigned when the user chooses
the activity to use for the device.
The user has the option of clicking the "always use this application" checkbox
to make the assignment automatic in the future.
The user may later clear this preference and revoke permission for an application
to have permission to communicate with the device by clicking the "Clear defaults"
button for the activity in the Manage Applications panel in Settings.

Added class UsbResolveActivity (a subclass or ResolveActivity for choosing
an activity for a USB device or accessory)

Added UsbDeviceManager, which manages the mapping between USB devices/accessories
and applications, including default applications for devices and accessories,
and manages application permissions.

Add interface to allow Settings to clear device and accessory
preferences and permissions for an application.

Remove obsolete ACCESS_USB permission.

Add new signatureOrSystem MANAGE_USB permission to allow administrating
preferences and permissions.

Moved UsbService.java to a "usb" subdirectory, along with new classes
UsbResolveActivity and UsbDeviceManager.

Change-Id: I92554381e9779e68ce380daaee4e1401fb875703
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-28 17:00:45 -08:00
Eric Laurent
4bb21c496b Fix issue 3479042.
The problem is that when an AudioRecord using the resampler is restarted,
the resampler state is not reset (as there is no reset function in the resampler).
The consequence is that the first time the record thread loop runs, it calls the resampler
which consumes the remaining data in the input buffer and when this buffer is released
the input index is incremented over the limit.

The fix consists in implementing a reset function in the resampler.

A similar problem was also present for playback but unoticed because the track buffer is always
drained by the mixer when a track stops. The only problem for playback was that the initial
phase fraction was wrong when restarting a track after stop (it was correct after a pause).

Change-Id: Ifc2585d685f4402d29f4afc63f6efd1d69265de3
2011-02-28 16:52:51 -08:00
Wink Saville
23fe005900 am 0eb6af89: Merge "Fixing the write of BackgroundData setting, DO NOT MERGE." into honeycomb
* commit '0eb6af892948ba23bf9de5c5a6172c6ec50f8f71':
  Fixing the write of BackgroundData setting, DO NOT MERGE.
2011-02-28 16:00:22 -08:00
Irfan Sheriff
ebe606fccd Using AsyncChannel for wifi connectivity
Change-Id: Ieee5a3a1a739238d8a6659493684f1be0cbea691
2011-02-28 15:54:51 -08:00
Wink Saville
d2ab6a19e0 Fixing the write of BackgroundData setting, DO NOT MERGE.
I outsmarted myself trying to minimize writes and caused no writes to occur.

bug:3485934
Change-Id: I43b6ebbed3f13277edfb2e28f09cf7b98ea66776
2011-02-28 15:32:41 -08:00
Adam Cohen
9611f2ea6c Small change to AppWidgetProviderInfo public field name and docs
Change-Id: Ia799cfc1824ccee1f7fd041ae8ecaa1a0395c3f6
2011-02-28 14:53:09 -08:00
Dianne Hackborn
d36d653c1c Merge "You can now specify a custom display size as NxM." 2011-02-28 11:28:38 -08:00
Dianne Hackborn
99aac7beca You can now specify a custom display size as NxM.
Change-Id: Ieb6df51aab009689f0f19b8887025261c5ceb69f
2011-02-28 11:23:18 -08:00
Xavier Ducrohet
b732b7b5e8 am ce57a7f3: am 6504490c: am dff6b8e7: Merge "Add --non-constant-id to aapt."
* commit 'ce57a7f35344e76689d30f45964d1e37b78280cb':
  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 10:10:38 -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
Jean-Michel Trivi
191ff092b8 Fix bug 3376700 Volume too loud at lowest setting
Change volume attenuation curve to provide more attenuation at
 low volume settings, and finer steps at high volume.
See bug entry for link to doc with curve values.

Change-Id: I750548b2161a4c550ef982ba793156e4518119e8
2011-02-27 16:41:21 -08:00
Jamie Gennis
f272ad210c am 0dc5fdb9: am e630e5f4: am 919853ce: Merge "Prevent SurfaceFlinger from using layer token 31." into gingerbread
* commit '0dc5fdb9b2fd3b3e2ede5e9607bc21423f357a01':
  Prevent SurfaceFlinger from using layer token 31.
2011-02-27 16:04:42 -08:00
Jamie Gennis
0dc5fdb9b2 am e630e5f4: am 919853ce: Merge "Prevent SurfaceFlinger from using layer token 31." into gingerbread
* commit 'e630e5f49ba15005172dceeda7299569b2d2351f':
  Prevent SurfaceFlinger from using layer token 31.
2011-02-27 15:55:21 -08:00
Jamie Gennis
e630e5f49b am 919853ce: Merge "Prevent SurfaceFlinger from using layer token 31." into gingerbread
* commit '919853ce244f853966817d4adb2f3b7b6e4bbe74':
  Prevent SurfaceFlinger from using layer token 31.
2011-02-27 15:44:36 -08:00
Jamie Gennis
919853ce24 Merge "Prevent SurfaceFlinger from using layer token 31." into gingerbread 2011-02-27 15:27:22 -08:00
Mike Lockwood
bbd460d76d am 6aea1154: DO NOT MERGE: KeyguardManager: Add isKeyguardLocked() and isKeyguardSecure()
* commit '6aea1154bae3a0935fdb9b09b2d91d9548232eb0':
  DO NOT MERGE: KeyguardManager: Add isKeyguardLocked() and isKeyguardSecure()
2011-02-26 13:21:05 -08:00
Mike Lockwood
6aea1154ba DO NOT MERGE: KeyguardManager: Add isKeyguardLocked() and isKeyguardSecure()
BUG: 3402847

Change-Id: I7cb199763e8d5386914b4c2173c9e1579b08674c
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-02-26 14:32:00 -05:00
Jeff Brown
33bbfd2232 Add support for mouse hover and scroll wheel.
Dispatch ACTION_HOVER_MOVE and ACTION_SCROLL through the View
hierarchy as onGenericTouchEvent.  Pointer events dispatched
this way are delivered to the view under the pointer.  Non-pointer
events continue to be delivered to the focused view.

Added scroll wheel support to AbsListView, ScrollView,
HorizontalScrollView and WebView.  Shift+VSCROLL is translated
to HSCROLL as appropriate.

Added logging of new pointer events in PointerLocationView.

Fixed a problem in EventHub when a USB device is removed that
resulted in a long stream of ENODEV errors being logged until INotify
noticed the device was gone.

Note that the new events are not supported by wallpapers at this time
because the wallpaper engine only delivers touch events.

Make all mouse buttons behave identically.  (Effectively we only
support one button.)

Change-Id: I9ab445ffb63c813fcb07db6693987b02475f3756
2011-02-25 17:06:07 -08:00
Dianne Hackborn
d752c3b3e6 Merge "Implement issue #3426299: Introduce application "stopped" state" 2011-02-25 16:15:27 -08:00