46500 Commits

Author SHA1 Message Date
Gloria Wang
54fe58562b Merge "- Change level of some LOGs from LOGE to LOGV because those logs are not error logs from non-DRMed content's point of view. - Add more mutex lock to avoid crash by multi-thread calls. - Fix for bug 4050039" into honeycomb-mr1 2011-03-09 16:05:59 -08:00
Gloria Wang
2ef2d49aa3 - Change level of some LOGs from LOGE to LOGV because those logs
are not error logs from non-DRMed content's point of view.
- Add more mutex lock to avoid crash by multi-thread calls.
- Fix for bug 4050039

Change-Id: I52fed22069f0cda6c4ac6a5363469168c797a33b
2011-03-09 15:51:46 -08:00
Dianne Hackborn
7b5cb3c033 Merge "Fix issue #4068088: NPE at com.android.internal.os.BatteryStatsImpl..." into honeycomb-mr1 2011-03-09 15:47:24 -08:00
Mike Lockwood
564f12ebe4 Merge changes Ifd78cca3,Ieadb86fe,If5b44ebd into honeycomb-mr1
* changes:
  MTP: Convert date created and modified values from seconds to milliseconds
  Update USB accessory compatibility library to support new requestPermission API
  UsbService: Don't require permissions for UsbManager.getCurrentAccessory()
2011-03-09 15:47:10 -08:00
Huahui Wu
37c2e3e556 Merge "b/4075349 Make the pinch to zoom more responsive after limits." into honeycomb-mr1 2011-03-09 15:37:56 -08:00
Huahui Wu
ff6f4c2eff b/4075349 Make the pinch to zoom more responsive after limits.
Change-Id: I66ea0aa95ff6a471b7c2ae2cb1ce2fdd0f18ce01
2011-03-09 15:13:01 -08:00
Jamie Gennis
6167a390e3 Merge "ANativeWindow: add queues-to-window-composer check." into honeycomb-mr1 2011-03-09 14:47:56 -08:00
Jim Miller
5c9248f668 Merge "Fix 4027057: Improve resolution of RecentApps thumbnail images." into honeycomb-mr1 2011-03-09 14:42:56 -08:00
Robert Ly
788dd5e076 am 2a36cf42: doc change: removing references to eclipse 3.4
* commit '2a36cf42fa6f941b2a55f7f391d79b93b8f780f4':
  doc change: removing references to eclipse 3.4
2011-03-09 14:39:55 -08:00
Mathias Agopian
838aa45b99 Merge "fix [4026375] SensorManager quaternion functions can call sqrt with a negative number" into honeycomb-mr1 2011-03-09 14:30:16 -08:00
Stephen Hines
c8a4b11e1f Merge "Fix a race condition during Context init/teardown." into honeycomb-mr1 2011-03-09 14:29:57 -08:00
Mike Lockwood
b966b9d9e8 MTP: Convert date created and modified values from seconds to milliseconds
BUG: 4026365

Change-Id: Ifd78cca305299ed1cedd6595609d9bf8d520cd8e
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-09 17:28:33 -05:00
Leon Scroggins
23c5861cde Merge "Scroll textfield onscreen when the IME shows." into honeycomb-mr1 2011-03-09 14:21:17 -08:00
Dianne Hackborn
32de2f67ea Fix issue #4068088: NPE at com.android.internal.os.BatteryStatsImpl...
...addHistoryRecordLocked(BatteryStatsImpl.java:1210)

It was doing a bunch of stuff without holding a lock!

Change-Id: Ie5b56514370e0bfc87ba7737d75e01df0859817e
2011-03-09 14:03:35 -08:00
Huahui Wu
166b190efc Merge "b/3307761 Clean up the flag mIsHandlingMultiTouch." into honeycomb-mr1 2011-03-09 13:55:35 -08:00
Mike Lockwood
580b641117 Update USB accessory compatibility library to support new requestPermission API
BUG: 4069037

Change-Id: Ieadb86fed577eeb7697d524e8a684ea6ea632f39
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-09 16:46:35 -05:00
Mike Lockwood
607710ad12 UsbService: Don't require permissions for UsbManager.getCurrentAccessory()
Permission check should only happen in openAccessory()
Otherwise an application will not be able to check for the current accessory
and ask for permissions (if it is a suitable match for the application)

BUG: 4069037

Change-Id: If5b44ebda2e8077598d96629163cc74aa336589e
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-09 16:43:35 -05:00
Leon Scroggins
d69b701284 Scroll textfield onscreen when the IME shows.
Bug:4079218
Change-Id: I69fe49582effe664c2288401871922a2cacc7c9c
2011-03-09 16:18:28 -05:00
Ed Heyl
b22bb1dae1 Merge "UsbManager: Fix broken Javadoc links" into honeycomb-mr1 2011-03-09 12:53:38 -08:00
Mike Lockwood
980f0430c1 UsbManager: Fix broken Javadoc links
Change-Id: Ia8ec7b29a7532feb00a28d6d325c129a9e041d2b
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-09 15:49:13 -05:00
Eric Laurent
cc34967fdc Merge "Fix issue 3439872: video chat and bluetooth SCO" into honeycomb-mr1 2011-03-09 10:56:01 -08:00
Shimeng (Simon) Wang
12c37cafe1 Merge "Consider mInitialScale when setting min zoom scale." into honeycomb-mr1 2011-03-09 10:48:57 -08:00
Mike Lockwood
2c3ed82600 Merge "Change UsbManager.requestPermission to only grant permission temporarily" into honeycomb-mr1 2011-03-09 10:44:19 -08:00
Robert Ly
2a36cf42fa doc change: removing references to eclipse 3.4
Change-Id: Iac1885a252266e7b15169588b91385cadf41295b
2011-03-09 10:39:26 -08:00
Jean-Michel Trivi
5fa7aac81b Merge "Fix bug 4064086 Use a death handler on audio focus changes from mode" into honeycomb-mr1 2011-03-09 10:18:31 -08:00
Mike Lockwood
c6f23e8521 Change UsbManager.requestPermission to only grant permission temporarily
If the user approves an application to access a USB device or accessory
without choosing it as the default application, then permission is granted
only until the device or accessory is disconnected.
Only applications chosen as the default choice have permissions assigned persistently.

BUG: 4061035

Change-Id: Ic4f6271a91b2fc56bbeef82c579e26d88c63ae56
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-09 12:33:00 -05:00
Irfan Sheriff
7ad85eb62f Merge "Persist wifi override in airplane mode" into honeycomb-mr1 2011-03-09 09:30:28 -08:00
Huahui Wu
9386a24eb1 b/3307761 Clean up the flag mIsHandlingMultiTouch.
The flag mIsHandlingMultiTouch was used to remove the out of order
touchMove events. After the fix b/3307761, it is no more needed.

Change-Id: I4d03131e2a22c53cc79c4105e39f078f1bea88ca
2011-03-09 09:26:36 -08:00
Patrick Scott
ea44c7c714 Merge "Pass the auto login header information to the app." into honeycomb-mr1 2011-03-09 05:05:21 -08:00
Kristian Monsen
9e697ee9fc Merge "Fix for bug 3469242 Turn of extra debugging before shipping" into honeycomb-mr1 2011-03-09 04:29:45 -08:00
Mike Lockwood
9e8e4ea0a8 Merge changes Ib517e5e4,I93be7695,I49bf22a4 into honeycomb-mr1
* changes:
  Close USB dialogs if their corresponding accessory or device has disconnected
  USB: Add API and dialog for apps to request permissions for USB devices and accessories
  UsbService: Automatically use system apps by default if it is the only choice
2011-03-09 03:52:47 -08:00
Jeff Brown
36b077d558 Merge "Eliminate some accidental log spam. (DO NOT MERGE)" into honeycomb-mr1 2011-03-09 02:45:59 -08:00
Adam Powell
12230eaa5f Merge "Fix bug 4065021 - Adjust spacing of the "home" action bar item to be consistent with the "up" indicator" into honeycomb-mr1 2011-03-09 00:22:53 -08:00
Adam Powell
2b0952b197 Fix bug 4065021 - Adjust spacing of the "home" action bar item to be
consistent with the "up" indicator

Make sure that the "home" affordance in the action bar always occupies
the same amount of space regardless of whether or not the "up"
indicator is visible. This means centering the application icon/logo
in the remaining space after the "up" indicator has been added.

Change-Id: I3c81cfe8255546d4dd676af913895713baba4f13
2011-03-09 00:17:42 -08:00
Romain Guy
812dba1fca Merge "Prevents NPE when a View was detached Bug #4068284" into honeycomb-mr1 2011-03-08 23:51:02 -08:00
Irfan Sheriff
658772f0e6 Persist wifi override in airplane mode
Persist the setting of wifi override in airplane mode
so that it can be restored on reboot

Bug: 3250824
Change-Id: I2af38c282ba55fc150fd9ef783d43600f0d4260f
2011-03-08 21:52:35 -08:00
Jim Miller
e70d506ab3 Fix 4027057: Improve resolution of RecentApps thumbnail images.
This fix ensures captured thumbnails in portrait mode have the
same resolution as those in landscape by fixing the horizontal
resolution and vertical resolution of the target image.

The returned image is now always the same size and matches
the landscape screen exactly. In portrait mode, it grabs
the upper portion of the screen based on the vertical dimension
of the target image.

Change-Id: I203c39843f2f21ca28f6ef0dffec308ce5cb39fb
2011-03-08 21:47:13 -08:00
Adam Powell
1250c94b50 Merge "Bug 3509417 - Refine touch event serialization" into honeycomb-mr1 2011-03-08 20:00:25 -08:00
Mike Lockwood
d591357524 Close USB dialogs if their corresponding accessory or device has disconnected
BUG: 4060065

Change-Id: Ib517e5e4a5422f9f0c8fca601308cecf7743c5d1
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-08 22:47:08 -05:00
Nicolas Roard
f986d496c5 Merge "Partial invalidation of the browser textures" into honeycomb-mr1 2011-03-08 19:02:33 -08:00
Scott Main
57e42c3726 am b0355410: docs: replace misc screenshots from Mac with shots from Windows bug: 3490831
* commit 'b0355410bb161c5e61408e57dc2adc085d337be9':
  docs: replace misc screenshots from Mac with shots from Windows bug: 3490831
2011-03-08 18:37:37 -08:00
Mike Lockwood
3a68b8338b USB: Add API and dialog for apps to request permissions for USB devices and accessories
New APIs:

UsbManager.hasPermission returns true if the caller has permission
for the given device or accessory

UsbManager.requestPermission poses a dialog to allow the user to give the caller
permission for the device or accessory.
Result is returned via a PendingIntent.
No dialog is displayed if the caller already has permission.

Also moved UsbResolverActivity to SystemUI package

BUG: 4069037

Change-Id: I93be769501a8776b49ac26e468af19f8fa2114c9
2011-03-08 21:22:19 -05:00
Scott Main
b0355410bb docs: replace misc screenshots from Mac with shots from Windows
bug: 3490831

Change-Id: Id99d397551d87817cd2625ee7f43a1671dfc7828
2011-03-08 18:02:58 -08:00
Romain Guy
e294d41593 Prevents NPE when a View was detached
Bug #4068284

Change-Id: Ied1c9b8d32a3e9957c6b165642ba40bbdaf35d53
2011-03-08 17:35:10 -08:00
Mike Lockwood
8c7d8c3ccb UsbService: Automatically use system apps by default if it is the only choice
If only one app is installed that supports a USB device or accessory
and that app is in the system partition, then use that activity by default
and rather than displaying the USB app chooser dialog.

BUG: 4060064

Change-Id: I49bf22a439e9676039b6f612c9bb622ab426066c
Signed-off-by: Mike Lockwood <lockwood@android.com>
2011-03-08 20:32:15 -05:00
Stephen Hines
cac8228e9c Fix a race condition during Context init/teardown.
This change makes Context initialization wait properly for all threads to be
available before leaving initContext(). This prevents a case where ~Context()
gets called before all created threads have started/finished their work. This
was triggered/discovered by running some very short-lived tests in CTS.

BUG=4064203

Change-Id: I1dd6f43fa7942c53881008e857df864e2395202e
2011-03-08 16:54:23 -08:00
Jamie Gennis
d2acedf18c ANativeWindow: add queues-to-window-composer check.
This change adds a new 'method' to the ANativeWindow interface to check
whether buffers queued to the window will be sent directly to the system
window compositor.

Change-Id: I4d4b199e328c110b68b250029aea650f03c8724d
Bug: 3495535
2011-03-08 16:49:51 -08:00
Jeff Brown
b23bdf518b Eliminate some accidental log spam. (DO NOT MERGE)
Used #ifdef where I should have used #if.

Change-Id: Ie3a083d601c89f4fc4d83244bb5060a202574dc2
2011-03-08 16:35:07 -08:00
Amith Yamasani
1f111f1172 Merge "Searchview layout cleanup. Some more tweaks required for Market." into honeycomb-mr1 2011-03-08 16:34:11 -08:00
Eric Laurent
421ddc014b Fix issue 3439872: video chat and bluetooth SCO
This change fixes the stability problems experienced when using
a bluetooth headset supporting both A2DP and SCO. Problems occur
when starting the video chat at which time the A2DP output is being
stopped to start SCO. At that time, active AudioTracks are invalidated
by AudioFlinger so that a new AudioTrack binder interface can be
recreated by the client process on the new mixer thread with correct parameters.
The problem was that the process to restore the binder interface was not
protected against concurrent requests which caused 2 binder interfaces
to be created sometimes. This could lead to permanent client deadlock
if one of the client threads was waiting for a condition of the first
created binder interface while the second one was created (as the AudioFlinger
would only signal conditions on the last one created).
This concurrent request situation is more likely to happen when a client
uses the JAVA AudioTrack as the JNI implementation uses simultaneously the
native AudioTrack callback and write push mechanisms. By doing so, the code
that checks if the binder interface should be restored (in obtainBuffer()) is
much more likely to be called concurrently from two different threads.

The fix consists in protecting the critical binder interface restore phase
with a flag in the AudioTrack control block. The first thread acting upon the binder
interface restore request will raise the flag and the second thread will just wait for
a condition to be signaled when the restore process is complete.

Also protected all accesses to the AudioTrack control block by a mutex to prevent
access while the track is being destroyed and restored. If a mutex cannot be held
(e.g because we call a callback function), acquire a strong reference on the IAudioTrack
to prevent its destruction while the cblk is being accessed.

Modified AudioTrack JNI to use GetByteArrayElements() instead of
GetPrimitiveArrayCritical() when writing audio buffers. Entering a critical section would
cause the JNI to abort if a mediaserver crash occurs during a write due to the AudioSystem
callback being called during the critical section when media server process restarts.
Anyway with current JNI implementation, either versions do not copy data most of the times
and the criticial version does not guaranty no data copy.

The same modifications have been made to AudioRecord.

Change-Id: Idc5aa711a04c3eee180cdd03f44fe17f3c4dcb52
2011-03-08 16:33:15 -08:00