diff options
author | Tony Wickham <twickham@google.com> | 2015-11-11 09:25:38 -0800 |
---|---|---|
committer | Tony Wickham <twickham@google.com> | 2015-12-03 14:18:06 -0800 |
commit | af78b59af19264105b8ce856defa5342d6fd584a (patch) | |
tree | 3c5625b918c2c2eeaf867f09147b37543c3e9a0d /tests | |
parent | b879abd2747c1c1473c8d2b9d9c97707da8218f3 (diff) | |
download | android_packages_apps_Trebuchet-af78b59af19264105b8ce856defa5342d6fd584a.tar.gz android_packages_apps_Trebuchet-af78b59af19264105b8ce856defa5342d6fd584a.tar.bz2 android_packages_apps_Trebuchet-af78b59af19264105b8ce856defa5342d6fd584a.zip |
Make sure pages are always accessible via left/right arrow keys.
- Handle NextPageFirstItem as first focusable item in reading order
- Handle PreviousPageLastItem as last focusable item in reading order
- Check the hotseat after the workspace in both cases above
- Dpad horizontal navigation (left/right) uses these as a last
resort (Rule3) to guarantee an item takes focus if a page exists
Note that it is necessary to search for a focusable item because
widgets are not yet focusable.
Bug: 25591057
Change-Id: I953648bd76c657d660a38427fdd4108bf9963c23
Diffstat (limited to 'tests')
-rw-r--r-- | tests/src/com/android/launcher3/util/FocusLogicTest.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/src/com/android/launcher3/util/FocusLogicTest.java b/tests/src/com/android/launcher3/util/FocusLogicTest.java index f93e91313..ee2442755 100644 --- a/tests/src/com/android/launcher3/util/FocusLogicTest.java +++ b/tests/src/com/android/launcher3/util/FocusLogicTest.java @@ -80,7 +80,7 @@ public final class FocusLogicTest extends AndroidTestCase { {100, -1, -1, -1, -1, -1}, }); int i = FocusLogic.handleKeyEvent(KeyEvent.KEYCODE_DPAD_RIGHT, 6, 5, map, 100, 1, 2, false); - assertEquals(0, i); + assertEquals(FocusLogic.NEXT_PAGE_FIRST_ITEM, i); } public void testMoveIntoHotseatWithEqualHotseatAndWorkspaceColumns() { |