8789 Commits

Author SHA1 Message Date
Adam Powell
dd8fab2629 TaskStackBuilder and Activity navigation features for framework
Promote navigation helpers from the support library to the core
platform.

The support library's meta-data element has been replaced with a
first-class parentActivityName attribute. This attribute is valid
on both activity and activity-alias elements. An activity-alias
will inherit the target activity's parentActivityName if one is
not explicitly specified.

Automatic Up navigation for Activities

Add the public method onNavigateUp() to Activity. The default
implementation will use the metadata supplied in the manifest about an
activity's hierarchical parent (parentActivityName) to do the right
thing.

If any activities in the parent chain require special Intent
arguments, the Activity subclass should override onNavigateUp() to
properly implement Up navigation for the app, supplying such arguments
as needed.

If automatic Up navigation within the same task can't find an activity
matching the supplied intent in the current task stack, it will act as
an in-app "home" and return to the root activity (presumably the app's
front page) in that task. (From this state, pressing "back" with
default behavior will return to the launcher.)

Change-Id: If163e27e59587f7af36975a09c986cb117ec3bc6
2012-04-05 11:45:10 -07:00
John Wang
963db55d59 Enhance Cell Location Api.
To boost accurary and enhance capability of cell location api,
two new APIs, TelephonyManager.getAllCellInfo() and
TelephonyManager.listen(LISTEN_CELL_INFO), are added. Two new
Class, CellInfo and CellIdentity, are created.

This API change returns all information of one cell locaiton
at the same time. It also provides additional LTE and timestamp information.

Change-Id: I4d0f813107e625ec4ac88c8d980ffd171aa5fc30
2012-04-05 11:30:37 -07:00
Dianne Hackborn
f87d19621d Clean up status bar, system bar, navigation bar management.
The status bar and navigation bar are two completely separate
elements, with their own semantics.  The system bar now classifies
itself as a navigation bar, since that is really how it behaves.

This required rewriting the HDMI resizing code, so that it is
all done by PhoneWindowManager since that is what is responsible
for the size of the navigation bar (and thus now system bar).  This
actually gets rid of a fair amount of code, and means we can also
do the same thing for a pure navigation bar.

Likewise the system bar now has the navigation bar ability to be
hidden when requested by system UI flags.  To get the behavior
we want on Xoom, we only allow the nav bar to be hidden when it
will help provide a better aspect ratio for showing widescreen
videos.

Finally the nav/system bar now animates when hidden and shown.

Change-Id: Ie927154b68376a0b61802f99171ff56b8da92e7a
2012-04-04 16:00:45 -07:00
Irfan Sheriff
689b741abc Merge "Add initial framework for DNS service discovery" 2012-04-04 12:34:52 -07:00
Irfan Sheriff
7d024d3724 Add initial framework for DNS service discovery
Change-Id: I53c0b7ebfd75e520ebb7553612f1aa8413b6b79b
2012-04-04 12:24:56 -07:00
Craig Mautner
c3a6cf79e3 Merge "First separation of animation from AppWindowToken." 2012-04-04 12:00:48 -07:00
Craig Mautner
0048dc9d55 Merge "Move more items between layout and animate sides." 2012-04-04 11:58:50 -07:00
Craig Mautner
594316361d First separation of animation from AppWindowToken.
New class AppWindowAnimator pulls animation out of AppWindowToken.

Change-Id: Ic1ccb6ec2bf091f1f901fe3c20cbeb242376ae6b
2012-04-04 11:56:44 -07:00
Craig Mautner
d09cc4ba24 Move more items between layout and animate sides.
- Isolate DimAnimator animation from the layout side.
- Isolate mWallpaperForceHidingChanged and mOrientationChangeComplete
  from the animation side.
- Eliminate a redundant setting of mOrientationChangeComplete to true.
  It was already true at that point.
- Synchronize changes to mWindows and mAppTokens on mAnimator. This is
  a nop until we go to multiple threads.
- Synchronize AppWindowToken.freezingScreen on mAnimator.
- Modification to repeat layout debugging including temporary enabling
  of spew on layout repeats.

Change-Id: Ic8d82b1c197144aaf6957caa5f71e175288220f2
2012-04-04 10:23:31 -07:00
Mathias Agopian
66ac90276a Merge "usea socketpair instead of a pipe in BitTube" 2012-04-03 15:38:14 -07:00
Mike Lockwood
69ccdbd78a Merge commit 'bc52ca2'
Conflicts:
	services/java/com/android/server/am/ActivityManagerService.java

Change-Id: I6da33a191a4ac13d08d8350a432b205e3dff85da
2012-04-03 11:53:47 -07:00
Amith Yamasani
15001eafa2 Merge "Dump the uid of a notification, for debugging." 2012-04-03 09:59:55 -07:00
Mathias Agopian
89c30a5486 usea socketpair instead of a pipe in BitTube
Bug: 6252830
Change-Id: I363cc7e9f73a5b7d8bbccee312c6d8938c84e99a
2012-04-02 18:38:02 -07:00
Amith Yamasani
191310b7d3 Merge "Fix a regression in activity manager regarding killing stopped processes." 2012-04-02 16:46:26 -07:00
Amith Yamasani
34db3d65d6 Fix a regression in activity manager regarding killing stopped processes.
Bug: 6275175
Change-Id: Ib1fa80cba9d21799f36fec999899e54a0fe8da51
2012-04-02 16:35:19 -07:00
Craig Mautner
1d60133578 Merge "Refactor to convert four state booleans to int." 2012-04-02 13:57:42 -07:00
Craig Mautner
749a7bb28b Refactor to convert four state booleans to int.
Replace four booleans (mDrawPending, mCommitDrawPending, mReadyToShow
and mHasDrawn) with a single int that can take on the four states.

Move mLastHidden from WindowState to WindowStateAnimator.

Change-Id: Ieff319dfa19123bf5a6cdc98e9ab28fd432b8153
2012-04-02 13:49:53 -07:00
Craig Mautner
ea7ff4d2fe Merge "Defer a couple of Surface actions for WSAnimator." 2012-04-02 13:24:55 -07:00
Craig Mautner
48ba1e7f53 Defer a couple of Surface actions for WSAnimator.
Perform the set-transparent-region-hint operation outside of the
WindowManagerService loop. This is to isolate the Surface operation
from the WindowManagerService inner loop.

Similarly, defer the setWallpaperOffset call so it's animation is not
coupled to the WindowManagerService inner loop.

Note that both operations are still being done on the
WindowManagerService thread.

Change-Id: I97f030b2a9b7cffe91c77342a299bfac6e59e9f8
2012-04-02 13:18:16 -07:00
Craig Mautner
5d724f50d4 Merge "Further isolate the Surface from WindowState." 2012-04-02 12:58:23 -07:00
Craig Mautner
c8bc97e530 Further isolate the Surface from WindowState.
Replace references to mWinAnimator.mSurface with new member
mHasSurface.

Clean up odd looping structures.

Simplify logging.

Change-Id: I9cc52a657044220d7b92528928b11bb18a724aef
2012-04-02 12:54:54 -07:00
Michael Jurka
e6c966caa3 Merge "Add frame counter to dumpGfxInfo" 2012-04-02 09:45:36 -07:00
satok
2c93efc9eb Hide ongoing notification icon when the screen is locked.
Bug: 5858903
Change-Id: Ibee9123f4a520e77f4baf8bdd3d75364ab451100
2012-04-02 19:54:28 +09:00
Dianne Hackborn
61d6c8ca49 Merge "Add new feature to let apps layout over status bar / system bar." 2012-03-30 17:36:32 -07:00
Dianne Hackborn
3a3a6cfd8e Add new feature to let apps layout over status bar / system bar.
The main change is a few new flags you can supply to
View.setSystemUiVisibility().  One is a new visibility mode,
SYSTEM_UI_FLAG_FULLSCREEN, which is basically the same as
the global FLAG_FULLSCREEN option for windows, but driven as
part of the system UI state.

There are also three new flags for telling the framework that you
would like to have your application's UI ignore screen
decorations -- SYSTEM_UI_FLAG_LAYOUT_NO_NAVIGATION for going
behind the navigation bar and SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN
for ignoring full screen decorations (that is the status bar).

In combination with this you can use SYSTEM_UI_FLAG_LAYOUT_STABLE
to have the framework report consistent insets to your application.

When using NO_NAVIGATION, when the user taps the screen we now
also automatically clear ONLY_CONTENT, so that we atomically show
both UI elements.  This should make it easy for apps like video
players that want to move between fully full-screen and regular
modes.

The ActionBar has also been extended when in overlay mode so
that it will adjust the system window insets to also account
for its space, and allow it to be hidden using the new
SYSTEM_UI_FLAG_FULLSCREEN.

Change-Id: Ic8db1adec49a0f420bfe40c1d92eb21307856d0b
2012-03-30 15:22:04 -07:00
Craig Mautner
4185012ad3 Merge "Move variables into animation class." 2012-03-30 13:22:21 -07:00
Craig Mautner
a608b88232 Move variables into animation class.
Moved drawPending and commitDrawPending and associated methods from
WindowState to WindowStateAnimator.

Created mechanism for passing results from WindowAnimator to
WindowManagerService. Initial results passed are mUpdateRotation and
mWallpaperMayChange.

Change-Id: Ib03d28f921580ac9426ea9233bea6eafc9ea964c
2012-03-30 13:19:45 -07:00
Amith Yamasani
0dedffd656 Dump the uid of a notification, for debugging.
Useful for multiuser testing.

Change-Id: I4aac8eda9b2f9c7ada07bd6a040260beb1acce87
2012-03-30 10:47:23 -07:00
Michael Jurka
a3fabff985 Add frame counter to dumpGfxInfo
Change-Id: I016f706e32cbdbce014795d8fc537b15c389dc7a
2012-03-30 05:06:55 -07:00
Michael Jurka
50c69b5d8a Merge "Preload recents on phones with hard nav keys" 2012-03-30 05:02:57 -07:00
Craig Mautner
15d5a964fd Merge "Remove obsolete variable masking valid one." 2012-03-29 18:03:32 -07:00
Craig Mautner
d87946ba48 Remove obsolete variable masking valid one.
The mUpdateRotation variable was still in the WindowManagerService
mInnerFields object. This was masking the true mUpdateRotation found in
WindowAnimator.

Fixes Bug 6240025.

Change-Id: I6531002f870f30d22e19ba9af5cac86e1c7b9bcb
2012-03-29 18:00:19 -07:00
Justin Koh
bc52ca2814 Stop ANR dialogs from appearing when ActivityManager dialogs should not be shown
Stop ANR dialogs from appearing on devices where the ActivityManager dialogs
should not be shown. Instead, kill the process. This is preferable because the
user can't actually do anything on the device.

TESTED = runs on device with that config, simulated ANR using test app.

Change-Id: I6267000afd12ef929f0c625220184c6ab0139552
2012-03-29 15:37:11 -07:00
Jeff Brown
a08f3e866a Merge "Enable vsync traversals by default." 2012-03-29 15:12:33 -07:00
Jeff Brown
ebb2d8d708 Enable vsync traversals by default.
Improved how the various callbacks are managed and sequenced
to reduce code duplication.

Added a heuristic to avoid postponing traversals until
the next vsync frame if we did not actually do any drawing during
the previous frame.  This helps in the very common case where
drawing occurs in response to input.

Change-Id: I277d9eeaf50408f8745a3cfd181db1d140770658
2012-03-29 13:10:55 -07:00
Craig Mautner
c2f9be0b7f Move Surface operations out of WindowState.
Migrated the bulk of Surface operations from WindowState to
WindowStateAnimator. There remain a multitude of cross-referencing
between the two classes and most of the other classes in the wm
package.

Change-Id: I4bfdfb84be31341371f3ef311aca8fc6a4966692
2012-03-29 11:31:12 -07:00
Craig Mautner
e7ae250540 Move wallpaper animations int WindowAnimator.
More refactoring. This time wallpaper animations were broken up from
WindowManagerService and the layout piece kept there while the
animation piece was moved into WindwoAnimator.

Also, applyAnimationLocked and applyEnterAnimationLocked were moved
from WindowManagerService to WindowState.

Change-Id: I05935023702ce05fdfdc804342ec14f719cdfea4
2012-03-29 11:31:11 -07:00
Michael Jurka
7f2668c846 Preload recents on phones with hard nav keys
Also refactor recents code across Phone/Tablet

Change-Id: Id557c5cb0f7d9378f81c40b20511a5d98bf4078e
2012-03-29 06:28:42 -07:00
Daniel Sandler
0833082c8e Merge "Stop showing ADB and MTP/PTP/USB notifications at the top." 2012-03-29 06:09:13 -07:00
Amith Yamasani
0184ce9295 Undo a previous change that's causing multi-user issues
Surgical hack for getting Settings to run multiple instances without
causing other system services/providers from doing the same.

Change-Id: Ic5dab61976a04c3012235299ba55edfcd8273dbb
2012-03-28 22:41:41 -07:00
Daniel Sandler
49a2ad1f40 Stop showing ADB and MTP/PTP/USB notifications at the top.
Two parts to this:
1. Stop treating FLAG_ONGOING_EVENT notifications specially
   (in particular, ordering them at the top of the panel).
2. Set the priority bits on the system UI notifications
   appropriately (low).

Change-Id: I3bde7e573654c5aad5e1c5d29e6a21ba94edcc5b
2012-03-29 00:42:16 -04:00
Amith Yamasani
79eeae4d69 Merge "Show the current user in power menu" 2012-03-28 18:47:52 -07:00
Amith Yamasani
52f1d752f9 Show the current user in power menu
Shows a little indicator next to the current user in the power menu
when multi-user is enabled.

Fixed a bug where Settings was sometimes being launched in the wrong
process when there are 2 instances running.

Change-Id: Iaf2a00f6d1871fd2a88d8982439e445423bb2896
2012-03-28 18:19:29 -07:00
Colin Cross
c8947b3d79 Merge "Move services/powermanager from frameworks/base to frameworks/native" 2012-03-28 14:12:30 -07:00
Irfan Sheriff
8a34718d84 Merge "Control suspend optimizations from framework" 2012-03-28 14:12:11 -07:00
Colin Cross
4be0041630 Move services/powermanager from frameworks/base to frameworks/native
Move services/powermanager into frameworks/native so audioflinger can
use it.  Note that this is not the same as a PowerManagerService,
which is part of systemserver and handles turning the screen on and
off, etc.  This is just a binder interface to allow taking wakelocks.

Change-Id: I1142e6d9ddbb651cc19ac07d946fa24d8feed8a3
2012-03-28 13:57:51 -07:00
James Dong
d927a1d996 Deleted the media, camera, drm related files since they are relocated
Change-Id: I9bc5573ee07e30b305b5b879023aa9ec69e10b91
2012-03-28 10:42:44 -07:00
Christopher Tate
3df92c50fe Merge "Fix uninstallation tracking in the Backup Manager" 2012-03-27 16:44:28 -07:00
Christopher Tate
a3d55342be Fix uninstallation tracking in the Backup Manager
This never worked properly; now it does.  We also no longer
do a redundant pair of remove/add operations when a package is
updated.

Bonus memory savings: we were keeping sets of ApplicationInfo
objects as part of the ongoing bookkeeping, but those were no longer
being used for anything other than the package names.  That's been
tossed out now and only the name strings are now used; hooray for
memory savings!

Change-Id: I4c6e592a1680e28550bcb4f76789260ded22280d
2012-03-27 16:29:35 -07:00
Amith Yamasani
8b5bce8d90 Merge "User management and switching" 2012-03-27 11:24:54 -07:00