76545 Commits

Author SHA1 Message Date
Eric Fischer
cf31066f81 Import translations. DO NOT MERGE
Change-Id: Ic1fae2f961943dc4304b2733edb54e65dd5c5526
2012-05-15 17:27:43 -07:00
Dianne Hackborn
bea7afc52c Merge "Fix issue #6284404: ArrayIndexOutOfBoundsException in..." into jb-dev 2012-05-15 13:57:06 -07:00
Adam Cohen
0a283346aa Merge "Adjusting default widget padding for sw600 dp devices (issue 6491977)" into jb-dev 2012-05-15 13:47:48 -07:00
Svetoslav Ganov
0bef72450b Merge "Implement the global accessibility action to expand notifications." into jb-dev 2012-05-15 13:41:25 -07:00
Adam Cohen
cd1b10b257 Adjusting default widget padding for sw600 dp devices (issue 6491977)
Change-Id: Ib5ae1452509f4f12c3bfc485b61251490a37960b
2012-05-15 13:38:02 -07:00
Daniel Sandler
8414beac87 Merge "Test new fonts and use correct OS version." into jb-dev 2012-05-15 13:30:41 -07:00
Svetoslav Ganov
5c89f44ea1 Implement the global accessibility action to expand notifications.
bug:6468852

Change-Id: Id4494a07b1ed96773e22dcfdd5991afe3ee98004
2012-05-15 13:28:14 -07:00
George Mount
d97d4f6cf6 Merge "Only open CAB for long-press." into jb-dev 2012-05-15 13:25:03 -07:00
Svetoslav Ganov
dff621968d Merge "Keeping the screen on during gesture detection." into jb-dev 2012-05-15 13:21:16 -07:00
Jeff Sharkey
df7adb3a44 Merge "Enable haptic feedback from ILockSettings." into jb-dev 2012-05-15 13:16:45 -07:00
Daniel Sandler
f89d5079e4 Test new fonts and use correct OS version.
Bug: 6499146
Change-Id: I83d6298725fe1f3385d5bf0a34487658583141a4
2012-05-15 16:15:15 -04:00
Dianne Hackborn
03fcc333cf Fix issue #6284404: ArrayIndexOutOfBoundsException in...
...FragmentManagerImpl.restoreAllState

This was a bug related to the difference between the pre- and post-HC
behavior of onSaveInstanceState().  Prior to HC, state was saved
before calling onPause().  Starting with HC, it is saved between
onPause() and onStop().  To maintain compatibility with existing
applications, there is a check in ActivityThread for pre-HC to in
that case emulate the behavior of old applications, still calling
onSaveInstanceState() before onPause() but using the state later.

One of the special cases we had to deal with in the old model of
saving state before pausing was restarting an activity that is
already paused.

Consider, for example: you have two activities on screen, the one on
top not fullscreen so you can see the one behind.  The top activity
is resumed, the behind activity is paused.  In the pre-HC world, the
behind activity would have already had its state saved.

Now you rotate the screen, and we need to restart the activities.
We need to destroy the behind activity and create a new instance,
but the new instance has to end up in the paused state.  To
accompish this, we restart it with a flag saying that it should
end up paused.  For the pre-HC world, since it ends up paused,
we need to make sure we still have its instance state kept around
in case we need it because we can't regenerate it (since it is
already paused).

So that is what the changed code here is doing.  It goes through
the normal create/start/resume steps, but holds on to the current
saved state so that it isn't lost when resume clears it, and then
puts the activity back to paused and stuffs that old saved state
back in to it.

The problem is that this code was doing it for every application,
even HC apps.  So we end up in a bad state, when a HC app has its
saved state sitting there as if it had been saved, even though it
is only paused.  Now if we go to restart the activity again, instead
of asking it for a new saved state (as we should for a HC app as
part of stopping it), we just re-use the existing saved state again.

Now this wouldn't generally be a huge problem.  Worst case, when we
restart the activity yet again we are just instantiating it from
the same saved state as we used last time, dropping whatever changes
may have happened in-between.  Who cares?  All it has been doing is
sitting there in the background, visible to the user, but not something
they can interact with.  If the activity made changes to its
fragments, those changes will be lost, and we will restore it from
the older state.

However...  if one of those fragements is a retained fragment, this
will *not* appear in the saved state, but actually be retained across
each activity instance.  And now we have a problem: if the retained
fragments are changed during this time, the next activity instance
will be created from the most recent state for the retained fragments,
but the older state for everyting else.  If these are inconsistent...
wham, dead app.

To fix this, just don't keep the saved state for HC apps.

Also includes a small optimization to ActivityStack to not push
the home screen to the front redundantly.

Change-Id: Ic3900b12940de25cdd7c5fb9a2a28fb1f4c6cd1a
2012-05-15 13:13:33 -07:00
Svetoslav Ganov
d1ff736d01 Keeping the screen on during gesture detection.
1. During gesture detection we are not injecting the events we receive
   since we do not want the accessibility focus to move as a result of
   the hover event of the gesture. Because of that it was possible that
   we consume all events since the user performs only gesture to navigate
   resulting in the screen being off while the user is actively interacting
   with the device. Now we are poking the user activity in the power
   manager to keep the screen on.

bug:6485171

Change-Id: I06a09c5297f01bef5e20d471cee76fa7aae0c4fe
2012-05-15 12:51:43 -07:00
Jeff Sharkey
d9016b2c94 Merge "Disable verbose RingtonePlayer debugging." into jb-dev 2012-05-15 12:43:48 -07:00
David Hu
981bd8a4cd Merge "Allow tests to run when bandwidth profiling fails" into jb-dev 2012-05-15 12:37:52 -07:00
Jeff Sharkey
3fb0af38a1 Enable haptic feedback from ILockSettings.
Bug: 6438580
Change-Id: I671ef3c7ac816596ab1944609bae672d1b0cb0ef
2012-05-15 12:37:51 -07:00
Amith Yamasani
0aeb05e6de Merge "Fix a problem in finish affinity in Activity Manager." into jb-dev 2012-05-15 12:01:55 -07:00
Svetoslav Ganov
0e3057c667 Merge "Add accessibility scroll support to some widgets." into jb-dev 2012-05-15 11:58:55 -07:00
Jeff Sharkey
b6e404a95f Disable verbose RingtonePlayer debugging.
Bug: 6491451
Change-Id: I41119599b5bbcc1a2bb717b3673e01e4b5366b9c
2012-05-15 11:36:11 -07:00
Jeff Sharkey
d6c1e49847 Merge "Migrate stream extras in CHOOSER intents." into jb-dev 2012-05-15 11:35:45 -07:00
Svetoslav Ganov
48d1586f40 Add accessibility scroll support to some widgets.
1. Added support for accessibility scroll action to
   some widgets that are scrollable.

2. Making the super call when handling an accessibility
   action in the views to call super first to allow
   an accessibility delegate to intercept the call.

bug:5932640

Change-Id: I5eb37d64bf9fba1d5c596981132e0df717e2a18a
2012-05-15 11:21:32 -07:00
Romain Guy
2298fe223f Merge "Avoid unnecessary copy when invoking drawBitmap(int[]) Bug #6483390" into jb-dev 2012-05-15 11:18:08 -07:00
Romain Guy
49c5fc0b9e Avoid unnecessary copy when invoking drawBitmap(int[])
Bug #6483390

Change-Id: I4d2d725ef50c9401b4bd998b6160128102b40745
2012-05-15 11:15:24 -07:00
Amith Yamasani
bfc1be1101 Fix a problem in finish affinity in Activity Manager.
Finishing tasks with an activity affinity was failing if the
activity was found at index 0. This fixes the loop condition.

Change-Id: If2e0d294e3e4493bca8b7efd40f24adaf2eb0b6f
2012-05-15 11:12:17 -07:00
Chris Wren
78cb7cf7d1 Allow animations to run past cancelled draws, if the view is visible.
Bug: 6475482
Change-Id: Iecb3a04744282135efa0049f1b70a46dc4a6bb23
2012-05-15 10:57:59 -07:00
Svetoslav Ganov
8b4d73b2d5 Merge "Revert "Showing default activity in activity chooser view only if enough space."" into jb-dev 2012-05-15 10:49:01 -07:00
Svetoslav Ganov
0e29ac9e4e Merge "Accessibility focus traversal in virtual nodes." into jb-dev 2012-05-15 10:48:44 -07:00
George Mount
899f609f78 Only open CAB for long-press.
Bug 6182286

Change-Id: I18590c457548e63cf45f5f7b626f5e8bd855f521
2012-05-15 08:28:28 -07:00
Chris Wren
66757217a6 Create separate dimensions for the notificaitons and notification rows.
Use notification heights on layouts internal to the notificaitons.
Use row heights where padding needs to be protected, on row layout decisions.
Clean up values-xhdpi/dimens.xml since there is no longer a values-hdpi/dimens.xml.

Bug: 6475098
Bug: 6489095
Change-Id: I44750574c6e23336585a432a38c5f1ba183b6cbc
2012-05-15 07:01:53 -07:00
Chris Wren
e9e3772534 Update both views for rich notifications.
Bug: 6475141
Change-Id: I24a87285e6385673c4a08cfa66b211228982a62e
2012-05-15 07:01:12 -07:00
Gilles Debunne
855f5407c7 Merge "Minor changes in SpellCheckSpan pool management in SpellChecker" into jb-dev 2012-05-15 02:57:00 -07:00
Svetoslav Ganov
b9f286e1a3 Revert "Showing default activity in activity chooser view only if enough space."
This reverts commit 340e2611de6d54516e222597585dbe7968a9915d

Change-Id: I396b70e8c737e6f1c36429618889e5c8fc690b55
2012-05-15 02:48:13 -07:00
Svetoslav Ganov
791fd31a68 Accessibility focus traversal in virtual nodes.
1. Finished the implementation of support for maintaining
   accessibility focus in view with virtual descendants.

2. Finished the NumberPicker implementation of virtual
   subtree such that all requred attributes are reported
   and ensuring that it support accessibility focus in
   its virtual descentants.

3. Fixed a bug where if a predecessor of the view that is
   accessiiblity focused is removed the accessibliity focus
   host in ViewRootImpl is not cleared leading to a crash
   when trying to draw the accessibility focus highlight.:

bug:6472646
bug:6433864

Change-Id: I3645642b87b4a26025c0b2ba9dfaad92d11a48f1
2012-05-15 00:43:53 -07:00
Romain Guy
7b8523aaed Merge "Remove all Dalvik allocations from Cavnas.drawBitmap(int[], ...)" into jb-dev 2012-05-14 20:12:09 -07:00
Romain Guy
e651cc6239 Remove all Dalvik allocations from Cavnas.drawBitmap(int[], ...)
Change-Id: Ie28538a2104d21154fdc78a56525e7403f08287d
2012-05-14 19:44:40 -07:00
Jeff Brown
e4db99cf87 Merge "Detect when pointer has stopped moving." into jb-dev 2012-05-14 19:18:15 -07:00
Jeff Brown
08b544c7be Merge "Fix pointer indexing issue in VelocityTracker." into jb-dev 2012-05-14 19:17:48 -07:00
Jeff Brown
90729403d5 Detect when pointer has stopped moving.
Some input devices do not generate ACTION_MOVE events while all
pointers have stopped, thereby lulling the VelocityTracker into
a false sense of complacency.  Before handling the following sample,
reset the VelocityTracker state so as not to be influenced by
earlier samples before the pointer stopped.  The velocity after
stopping is assumed to be discontinuous.

Bug: 6413587
Change-Id: I6387bc036ff141d083d3d17a89e37eeaa3188349
2012-05-14 18:57:05 -07:00
Jim Miller
a5b2d48700 Merge "Fix 6483412: Disable search from navbar while SUW is running" into jb-dev 2012-05-14 18:56:53 -07:00
Jeff Brown
47a4a50df0 Merge "Improve touch event resampling." into jb-dev 2012-05-14 18:52:59 -07:00
Jeff Brown
dcab190bd2 Fix pointer indexing issue in VelocityTracker.
VelocityTracker was implicitly assuming that the pointer ids in
a MotionEvent were ordered.  That is not necessarily the case
so we need to be careful while copying the pointer coordinates out.

Bug: 6413587
Change-Id: I3b23a954f893eebdf786f2a94207149b092ef036
2012-05-14 18:44:17 -07:00
Jeff Brown
7174a491bc Improve touch event resampling.
Fixed a few bugs related to the id-to-index mapping for
pointer coordinates.

Tightened the bounds on the resampling time interval to
avoid predicting too far into the future.

Only lerp X and Y components of motion events.

Alter the future to satisfy past predictions.  (Rewrite touch
events to conceal obvious discontinuities.)

Added a system property to control whether resampling is enabled
for debugging purposes.

Bug: 6375101
Change-Id: I35972d63278bc4e78148053a4125ad9abeebfedb
2012-05-14 18:31:53 -07:00
Svetoslav Ganov
8ce2d78aa8 Merge "Improving accessibility focus traversal." into jb-dev 2012-05-14 18:26:24 -07:00
David Hu
71a0d06fd8 Allow tests to run when bandwidth profiling fails
When bandwidth profiling fails due to lack of kernel module
the test should still be able to run.

Change-Id: Ib111989d2892b05c147889e562e77035fab05140
2012-05-14 18:13:19 -07:00
Jeff Sharkey
3b7d1ef4be Migrate stream extras in CHOOSER intents.
When sending CHOOSER intent, inspect its target for any EXTRA_STREAM
needing migration. If any migration happens, copy the ClipData to
the CHOOSER intent and set GRANT_READ flag. Also update CHOOSER docs.

Bug: 6463773
Change-Id: I66a7adf7bf6f2f173866925cb7e048f4c7a63222
2012-05-14 17:37:11 -07:00
Dianne Hackborn
a827843f9b Merge "Fix issue #6020164: Settings crashed on orientation change..." into jb-dev 2012-05-14 17:31:53 -07:00
Adam Powell
e48d12b780 Merge "Fix ActionProviders that have submenus" into jb-dev 2012-05-14 17:24:24 -07:00
Adam Powell
9e8b7406ca Merge "Fix text coloring for action mode "close" option" into jb-dev 2012-05-14 17:23:54 -07:00
Dianne Hackborn
b61a02657b Fix issue #6020164: Settings crashed on orientation change...
...while listening to TTS example

This was a nice one.  What was happening is that immediately upon
being created, the activity was starting another activity in a
different process.  The second activity would never show, just
immediately exit.  However the original activity had time to
pause and get into stopping itself before the second activity had
come back to the activity manager to say it was going away, resulting
in the activity manager asking the original activity to resume.

At this point the activity manager's state is that the second
activity is finishing and gone, and the original activity is
resumed.  However in the app process the original activity is
still working on stopping itself, and it eventually completes
this and tells the activity manager.  The activity manager now
changes its state to STOPPED, even though it is actually resumed
and that is the last thing it told it to be, and it is now
proceeding to set itself in that state.

This would result later in the activity manager sending an
unnecessary state change to the application.  In the case of
the screen here, we next do a rotation change, the activity
manager thinks the current state is STOPPED not RESUMED, so it
tells the application to relaunch the activity in a new config
but not in the resumed state.  Now it does the whole "start a
new temporary activity" thing again, at which point it tries
to pause the original activity again, and we have an unbalanced
onPause() call to the app and it falls over.

Change-Id: I38b680746f4c61ae30e7ce831e1de187adf60902
2012-05-14 17:19:18 -07:00
Jeff Brown
00ff47484f Merge "More VelocityTracker refactoring." into jb-dev 2012-05-14 17:12:32 -07:00