OSDN Git Service

Converting action bars to clusters.
authorVadim Tryshev <vadimt@google.com>
Sat, 7 Jan 2017 03:30:00 +0000 (19:30 -0800)
committerVadim Tryshev <vadimt@google.com>
Thu, 12 Jan 2017 01:19:39 +0000 (17:19 -0800)
commit1abe85c867f552a5cdf50fba3f60d796284c2102
tree5d89807e94b5f485567da990184d9f9a68432ee5
parent4a07b95746fe794ec5411aad9f5334178fb641b4
Converting action bars to clusters.

ActionBar keyboard navigation logic is now implemented via clusters.
Old implementation using setTouchscreenBlocksFocus and Ctrl+Shift+<
shortcut is removed.

Looking at the code, I can’t rule out existence of all 3 categories
(1) action bars with a nested toolbar, (2) action bars without a
nested toolbar and (3) Toolbars outside of action bars.
Because of this, I set “cluster” attribute both on action bar and
toolbar, and have code to avoid nested clusters in case (1).

Support lib’s action/tool bars aren’t converted, however, they
didn’t regress since Ctrl+Shift+< never worked for them. Will be
done after feature freeze.

Bug: 32151632
Test: Manual checks.
Change-Id: Ieb93980088c0fb385a9bc8a5d218ffc269b94dc5
core/java/android/app/ActionBar.java
core/java/android/app/Activity.java
core/java/android/widget/Toolbar.java
core/java/com/android/internal/app/ToolbarActionBar.java
core/java/com/android/internal/app/WindowDecorActionBar.java
core/res/res/layout/screen_action_bar.xml
core/res/res/layout/screen_toolbar.xml
core/res/res/values/styles.xml