OSDN Git Service

Unify normal and overlay action bar layouts.
authorDianne Hackborn <hackbod@google.com>
Tue, 26 Feb 2013 22:53:55 +0000 (14:53 -0800)
committerDianne Hackborn <hackbod@google.com>
Thu, 28 Feb 2013 02:27:42 +0000 (18:27 -0800)
commitdf7221ced3b7cd807f14e84c302fc09fd659fd68
tree2e5cdc00c406f577492a7168580fa6c127b0a1f4
parentd0d209ed4d6280b6e1203eebe823f04f9db766c0
Unify normal and overlay action bar layouts.

Switch the action bar to always use the overlay layout, and
make it smarter to do the right thing depending on whether the
action bar is in overlay mode or not.

This allows apps to use the system UI magic flags without
having to worry about whether the action bar is configured
in overlay mode or note -- just select a stable layout and it
will automatically go into overlay mode.

In the future this should also allow us to simplify the action
bar code, since it is all sitting on one common implementation.
For example, much of the logic in ActionBarImpl can be moved
to the root action bar layout, and that layout can be optimized
to do custom layout with all of the known elements it has.

Also fixed a little bug in the performance tests.

Change-Id: Iec0c0c0699754f0d1ce37402d786b4966e052a56
core/java/com/android/internal/app/ActionBarImpl.java
core/java/com/android/internal/widget/ActionBarOverlayLayout.java
core/res/res/layout/screen_action_bar.xml
core/res/res/layout/screen_action_bar_overlay.xml [deleted file]
policy/src/com/android/internal/policy/impl/PhoneWindow.java
tests/FrameworkPerf/src/com/android/frameworkperf/FrameworkPerfActivity.java
tests/FrameworkPerf/src/com/android/frameworkperf/TestService.java