1046 Commits

Author SHA1 Message Date
Eric Olsen
4499ad729a Fix bad merge fixes build breakage.
Signed-off-by: Eric Olsen <eolsen@android.com>
2009-11-04 17:12:41 -08:00
Android (Google) Code Review
9053fdb32b Merge change I76127f6f into eclair
* changes:
  Add support for colored LED on jogball backlight.
2009-11-04 19:39:29 -05:00
Eric Olsen
f42f15cf45 Add support for colored LED on jogball backlight.
Signed-off-by: Eric Olsen <eolsen@android.com>
2009-11-04 14:31:26 -08:00
Christopher Tate
78dd4a7371 Fix #2176803 - restores from userdebug to user builds not working
The underlying issue is that ordinarily, the restore mechanism checks the
signature block of the package which uploaded the restore data against the
signature of the package on-device that will be handling the restore.  This is
to ensure that the restore goes to the "same" application as the one that
uploaded it.

However, applications bundled on the system partition as part of the device
build are signed not with a permanent, app-identifying signature, but rather
with the device's signature block, which is different for each kind of device
and potentially between kinds of build for the same device.  That renders the
stored backup data unusable when changing devices / builds / etc.

This change works around the problem by explicitly privileging applications that
reside on the system partition:  they have been built into the device, and so
are trusted to be able to handle data that is marked as coming from its package
name.

Change-Id: I561011bce2b54cff3e695e82e7544b126b6ac31e
2009-11-04 13:27:56 -08:00
Mike Lockwood
27c6dd7aa4 PowerManagerService: Fix manual brightness mode.
Change-Id: I10aec64e3f7ae2715475b9797565747295c19a00
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-11-04 08:57:07 -05:00
Amith Yamasani
6179126dad Fix 2233444 (No IME).
Fix the flags for the StatusBarExpanded window that were causing the Window Manager to
think that it needed input.
2009-11-03 13:22:24 -08:00
Amith Yamasani
ed564b319d Revert "Revert "Fix notification bar performance.""
This reverts commit 6e8f47b0ed2ffdb55b695d9f154cccd3ea3c98de.
2009-11-03 13:20:21 -08:00
Amith Yamasani
dcdd29781a Revert "Revert "fix 2233092 - Notification shade gets stuck half-open""
This reverts commit b96a9d9296925fef6a1c0e5ad4d847d96bf9acb5.
2009-11-03 13:18:03 -08:00
Android Git Automerger
b96a9d9296 Revert "fix 2233092 - Notification shade gets stuck half-open"
As per Dr. No; revert commit 6a7899a8d6444989657d1058666269263b5b50c0.
2009-11-03 12:29:46 -08:00
Android Git Automerger
6e8f47b0ed Revert "Fix notification bar performance."
As per Dr. No; revert commit 0d7dc3b800d0489c43ad9071615b2b4ebec80443.
2009-11-03 12:26:15 -08:00
Android (Google) Code Review
d2c6879436 Merge changes I116424c4,Ibd0ef67f into eclair
* changes:
  Remove obsolete hardware auto-brightness support.
  Add documentation for proximity and light sensors.
2009-11-03 12:32:04 -05:00
Joe Onorato
6a7899a8d6 fix 2233092 - Notification shade gets stuck half-open
Follow up to bug 2195678.  This was one of the reprocussions that
I was worried about with respect to that bug, so I'm counting
Dr. No on that change as the one for this one.
2009-11-03 12:22:33 -05:00
Mike Lockwood
f90ffcc639 Remove obsolete hardware auto-brightness support.
Change-Id: Ibd0ef67f887254f26ce19faf0627f8b246ec0a18
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-11-03 11:41:27 -05:00
Android (Google) Code Review
afd81beb33 Merge change Icbb3aa0a into eclair
* changes:
  Use setRepeating() rather than setInexactRepeating() for backup scheduling, and add some random fuzz to the scheduling times, to make sure we aren't creating hour-aligned server load spikes.
2009-11-02 16:58:26 -05:00
Android (Google) Code Review
cce9f0fa86 Merge change I0d7dc3b8 into eclair
* changes:
  Fix notification bar performance.
2009-11-02 16:29:31 -05:00
Joe Onorato
0d7dc3b800 Fix notification bar performance.
Bug 2195678

We had all this stuff there to keep the notification view
around so it doesn't need to be reconstructed each time,
and we weren't using it.  This fixes that, and it looks
much better now.
2009-11-02 16:20:44 -05:00
Mike Lockwood
952211b4ae Fix problem with proximity sensor not reawaking screen if the values change too quickly.
The logic that disables user activity while turning off the screen should not affect proximity sensor.

Fixes bug b/2228734 (in-call, prox sensor gets confused)

Change-Id: Ieca126e6f79bf7baa5741981aea72d306ba03edc
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-11-02 14:17:57 -05:00
Mike Lockwood
f1d14f6a33 Do not advance mLastEventTime when enabling or disabling user activity.
Fixes a race condition between the keyguard and power key that sometimes resulted
in the power key failing to turn off the screen.

Fixes bug b/2212852 (Power button does not put phone to sleep)

Change-Id: I92498c5fddf2bfc32b105ea1a7ea14a06d83888e
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-11-02 11:56:59 -05:00
Mike Lockwood
9efd523c46 Add warning that hardware auto-brightness is deprecated and will be removed in the next release.
Change-Id: I90eae78f71f377f6479d0aaf7ced38a7b988a7ee
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-11-01 10:05:50 -05:00
Mike Lockwood
4984e73dc5 Manage button and keyboard backlights with light sensor in both manual and automatic mode.
Now the manual brightness mode only applies to the LCD backlight and
button and keyboard backlights are always managed automatically.

Fixes bug b/2195798 (Passion capacitive key backlights don't always come on)

This change only affects the framework based auto-brightness implementation.
Hardware auto-brightness is not affected.

Change-Id: Ib88310d642d498591e8879c8269d630ff3f7c8af
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-11-01 08:20:42 -05:00
Mike Lockwood
df024920eb Don't turn on keyboard backlights when keyboard is closed in auto brightness mode.
For framework light sensor support (does not affect hardware based approach).

Change-Id: I6896a7c5b3fd3ed136c4f25c63a0e5813c349f68
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-31 17:05:00 -04:00
Mike Lockwood
aa66ea880f Use separate flags for enabling hardware and software auto-brightness.
This cleans up the code in preparation for some other auto-brightness changes
and fixes support for devices without light sensors.

Change-Id: I3d4802cf860a865ffd86a8bb57cd57b46359433d
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-31 16:31:27 -04:00
Dan Egnor
c1c49c024f Use setRepeating() rather than setInexactRepeating() for backup scheduling,
and add some random fuzz to the scheduling times, to make sure we aren't
creating hour-aligned server load spikes.

See bug 2226553 for details & Dr. No information.
2009-10-30 18:12:29 -07:00
Suchi Amalapurapu
d83006cbe8 When upgrading packages with shared user ids make sure we are eliminating
the package about to be deleted or upgraded when updating permissions associated
with the shared user. Include a simple null check when retrieving the permission.

Fix PackageParser to avoid ArrayIndexOutOfBounds exceptions in several places
2009-10-29 00:46:55 -07:00
Suchi Amalapurapu
c03d28b9e9 Check that the window which wants to force hide is visible before setting the flag forceHiding to true. If we do layout the surfaces
again this flag gets set no matter what since the keyguard window is always present in the list of tokens and this hides the window which would
have become visible since the keyguard just got dismissed.
This causes unnecessary focus changes due to changes in visibility of current window.

This will resolve issues related to current focus and time outs when dispatching key events.
2009-10-28 14:47:45 -07:00
Android (Google) Code Review
763ccae7d7 Merge change I8e7f5f07 into eclair
* changes:
  DO NOT MERGE: Fix loss of focus after wakeup into incall screen
2009-10-28 15:09:29 -04:00
Christopher Tate
405d089863 DO NOT MERGE: Fix loss of focus after wakeup into incall screen
Because of the asynchronous behavior of keyguard, and incall explicitly
disabling keyguard, sometimes the window manager would wind up in a state in
which the "correct" app and activity window were shown, but focus was
recalculated "too soon," at a time when keyguard was just about gone but not
quite, and incall was not yet fully shown.  In this case there was no currently
valid event target, but the final show of the incall window would not prompt a
focus recalculation, so that "no current focus" state would incorrectly persist,
resulting in spurious ANRs until some other phone activity forced a focus
update.

We now detect the problematic case when windows are shown, and make sure to
recalculate focus explicitly thereafter.  This change does *not* fix the
underlying race conditions that have been resulting in mismatched state within
the window manager, but it does force a validation pass that puts things in
order so that normal operation can continue.

Change-Id: I8e7f5f0795f0042a0da074aeed385e3fbc210360
2009-10-28 11:52:58 -07:00
Android (Google) Code Review
fb872d1af3 Merge change Id4d04def into eclair
* changes:
  Fix a race that kept the locale picker from working under heavy CPU load.
2009-10-28 13:18:39 -04:00
Mike Lockwood
0506712068 A better solution for ignoring user activity while the screen is animating off.
Fixes a deadlock that occurred because mAnimatingScreenOff was left set to true
after aborting turning off the screen.
This change removes the mAnimatingScreenOff flag and checks for
(mScreenBrightness.animating && mScreenBrightness.targetValue == 0) instead.

Fixes bug b/2219706

Change-Id: I081f08c14ad7585a953fb567867238b1f3db841f
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-27 23:13:39 -04:00
Eric Fischer
d4d04def2c Fix a race that kept the locale picker from working under heavy CPU load.
The locale picker and the activity transition would both change the
configuration, and depending upon the timing, the activity transition
would undo what the locale picker had just done.  Usually it worked right,
but would often fail if the user changed locales just after a data wipe,
when the media scanner was working hard in the background to index
the contents of the SD card.

http://b/issue?id=2216298
2009-10-27 18:55:57 -07:00
Mike Lockwood
dd9668ec63 PowerManagerService: Animate LCD backlight changes due to autobrightness support.
Change-Id: I9c242127df801125c30f399198d1f7e9c8579612
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-27 15:47:03 -04:00
Mike Lockwood
2d155d264e PowerManagerService: Fix bug resulting in backlights turning on while screen is off.
Fixes bugs b/2216879 and b/2197060

Change-Id: I5de3cbdbc0601dd7950dba74cacfff06d41ad18e
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-27 09:47:50 -04:00
Mike Lockwood
809ad0fce3 PowerManagerService: Clear Binder calling identity around calls to Sensor Manager.
This fixes a problem that resulted in bogus battery statistics for the prox and light sensors
due to the sensors being enabled in an app's context and disabled in the system context.

Fixes problems reported in bug b/2211960

Change-Id: Ib0d3d9d06f043b386d3b8d494b9bad5bd40bb6e1
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-26 22:12:06 -04:00
Mike Lockwood
86328a99bd LocationManagerService: clear calling identity in mock provider calls.
Fixes bug b/2198028 (testDirectionsFromScratchByTyping fails because of android.permission.ACCESS_WIFI_STATE)

Change-Id: I44e95981d805189ed6d906d388c5189ee788802f
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-26 16:18:58 -04:00
Mike Lockwood
3333fa4f3d PowerManagerService: Ensure that recent changes do not effect the hardware ALS case.
Change-Id: I42d2d1331c2a6234dfbdaa99f0cc8ab249f7ce22
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-26 14:52:00 -04:00
Mike Lockwood
6eb14c3038 PowerManagerService: Do not enable light sensor if hardware backlight management is being used.
Change-Id: Ic652ac22ec3256d71d12504148927349dfbd3384
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-24 19:43:38 -04:00
Dianne Hackborn
7580493b01 Implement feature #2117336: Create event communication APIs for live wallpaper
Note: currently only implements an async version (no result), and not yet
actually tested.

Change-Id: Id47ed045a4b0eb309ea8c58daf41a0e03eff1d3a
2009-10-22 20:10:53 -07:00
Android (Google) Code Review
94f2c52421 Merge change I63c2d9ed into eclair
* changes:
  Update the names of the widgets when the locale changes.
2009-10-22 18:38:29 -04:00
Eric Fischer
63c2d9ed9c Update the names of the widgets when the locale changes.
Bug 1814373, Bug 2152730
2009-10-22 15:28:05 -07:00
Mike Lockwood
3c9435a205 PowerManager: Don't poke user activity in setKeyboardVisibility unless the state actually changed.
Fixes bug b/2158297 (lock screen should time out after 7 seconds)

Change-Id: Ia3f7ef6464129ab78283923dbfd7f7472136e676
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-22 15:45:37 -04:00
Android (Google) Code Review
fee0f57733 Merge change I99dc6477 into eclair
* changes:
  Add WindowManagerPolicy.allowKeyRepeat() method for disabling key repeats.
2009-10-22 07:07:04 -04:00
Android (Google) Code Review
eadb97b482 Merge change I53f83502 into eclair
* changes:
  PowerManagerService: Ignore user activity while the screen is animating off.
2009-10-22 07:06:51 -04:00
Mike Lockwood
3d0ea72dd7 Add WindowManagerPolicy.allowKeyRepeat() method for disabling key repeats.
Part of a fix for bug b/2198537

Change-Id: I99dc64772fa7644b12432d5549603025196ea3e2
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-21 23:08:13 -04:00
Mike Lockwood
f003c0c15d PowerManagerService: Ignore user activity while the screen is animating off.
Fixes bug b/2202165 (Often I when pressing power to turn off I get the lock screen)

Change-Id: I53f8350203d57fbb5f143edc44985879caadd78f
Signed-off-by: Mike Lockwood <lockwood@android.com>
2009-10-21 23:06:56 -04:00
Android (Google) Code Review
0737b16430 Merge change I959a6f46 into eclair
* changes:
  Fix bug	2194213: Non-default system IMEs are enabled, but not initially shown in input method switcher.     - Ensure system IMEs are put on the enabled list at startup/install.     - If the default IME is not installed, choose another one whenever building input method list.
2009-10-21 22:58:39 -04:00
Brandon Ballinger
6da35a0c12 Fix bug 2194213: Non-default system IMEs are enabled, but not initially shown in input method switcher.
- Ensure system IMEs are put on the enabled list at startup/install.
    - If the default IME is not installed, choose another one whenever building input method list.
2009-10-21 18:24:29 -07:00
Android (Google) Code Review
8d9ddbe2aa Merge change I1f30f3f1 into eclair
* changes:
  Fix #2201615: getCallingPackage returns calling process instead of calling package
2009-10-20 19:14:20 -04:00
Android (Google) Code Review
5b48223d0e Merge change I14e833fa into eclair
* changes:
  If we fail to persist the current settings and fall back to the back settings file when reading settings in PackageManager, we might rename the corrupted settings to backup(in case of power failure between the earlier write failure and file deletion) and end up loosing both files. So just clear up the corrupted current settings file if we have backup. The backup wouldn't exist if everything went well with persisting the earlier settings.
2009-10-20 18:51:06 -04:00
Dianne Hackborn
9bbcb916c5 Fix #2201615: getCallingPackage returns calling process instead of calling package
Change-Id: I1f30f3f1ce8928796c1ab502d0c2dc02de86e8e7
2009-10-20 15:42:38 -07:00
Suchi Amalapurapu
14e833faa0 If we fail to persist the current settings and fall back to the back settings file
when reading settings in PackageManager, we might rename the corrupted settings to
backup(in case of power failure between the earlier write failure and file deletion)
and end up loosing both files.
So just clear up the corrupted current settings file if we have backup.
The backup wouldn't exist if everything went well with persisting the earlier settings.

We do this in both read and write just in case.
2009-10-20 13:26:37 -07:00