Loading src/com/android/launcher3/testing/TestInformationHandler.java +5 −0 Original line number Diff line number Diff line Loading @@ -165,6 +165,11 @@ public class TestInformationHandler implements ResourceBasedOverride { response.putBoolean(TestProtocol.TEST_INFO_RESPONSE_FIELD, mDeviceProfile.isTablet); return response; case TestProtocol.REQUEST_NUM_ALL_APPS_COLUMNS: response.putInt(TestProtocol.TEST_INFO_RESPONSE_FIELD, mDeviceProfile.numShownAllAppsColumns); return response; case TestProtocol.REQUEST_IS_TWO_PANELS: response.putBoolean(TestProtocol.TEST_INFO_RESPONSE_FIELD, FOLDABLE_SINGLE_PAGE.get() ? false : mDeviceProfile.isTwoPanels); Loading tests/shared/com/android/launcher3/testing/shared/TestProtocol.java +1 −0 Original line number Diff line number Diff line Loading @@ -115,6 +115,7 @@ public final class TestProtocol { public static final String REQUEST_CLEAR_DATA = "clear-data"; public static final String REQUEST_HOTSEAT_ICON_NAMES = "get-hotseat-icon-names"; public static final String REQUEST_IS_TABLET = "is-tablet"; public static final String REQUEST_NUM_ALL_APPS_COLUMNS = "num-all-apps-columns"; public static final String REQUEST_IS_TWO_PANELS = "is-two-panel"; public static final String REQUEST_START_DRAG_THRESHOLD = "start-drag-threshold"; public static final String REQUEST_SHELL_DRAG_READY = "shell-drag-ready"; Loading tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java +6 −0 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ import static android.view.MotionEvent.AXIS_GESTURE_SWIPE_FINGER_COUNT; import static com.android.launcher3.tapl.Folder.FOLDER_CONTENT_RES_ID; import static com.android.launcher3.tapl.TestHelpers.getOverviewPackageName; import static com.android.launcher3.testing.shared.TestProtocol.NORMAL_STATE_ORDINAL; import static com.android.launcher3.testing.shared.TestProtocol.REQUEST_NUM_ALL_APPS_COLUMNS; import android.app.ActivityManager; import android.app.Instrumentation; Loading Loading @@ -353,6 +354,11 @@ public final class LauncherInstrumentation { .getParcelable(TestProtocol.TEST_INFO_RESPONSE_FIELD); } public int getNumAllAppsColumns() { return getTestInfo(REQUEST_NUM_ALL_APPS_COLUMNS).getInt( TestProtocol.TEST_INFO_RESPONSE_FIELD); } public boolean isTablet() { return getTestInfo(TestProtocol.REQUEST_IS_TABLET) .getBoolean(TestProtocol.TEST_INFO_RESPONSE_FIELD); Loading Loading
src/com/android/launcher3/testing/TestInformationHandler.java +5 −0 Original line number Diff line number Diff line Loading @@ -165,6 +165,11 @@ public class TestInformationHandler implements ResourceBasedOverride { response.putBoolean(TestProtocol.TEST_INFO_RESPONSE_FIELD, mDeviceProfile.isTablet); return response; case TestProtocol.REQUEST_NUM_ALL_APPS_COLUMNS: response.putInt(TestProtocol.TEST_INFO_RESPONSE_FIELD, mDeviceProfile.numShownAllAppsColumns); return response; case TestProtocol.REQUEST_IS_TWO_PANELS: response.putBoolean(TestProtocol.TEST_INFO_RESPONSE_FIELD, FOLDABLE_SINGLE_PAGE.get() ? false : mDeviceProfile.isTwoPanels); Loading
tests/shared/com/android/launcher3/testing/shared/TestProtocol.java +1 −0 Original line number Diff line number Diff line Loading @@ -115,6 +115,7 @@ public final class TestProtocol { public static final String REQUEST_CLEAR_DATA = "clear-data"; public static final String REQUEST_HOTSEAT_ICON_NAMES = "get-hotseat-icon-names"; public static final String REQUEST_IS_TABLET = "is-tablet"; public static final String REQUEST_NUM_ALL_APPS_COLUMNS = "num-all-apps-columns"; public static final String REQUEST_IS_TWO_PANELS = "is-two-panel"; public static final String REQUEST_START_DRAG_THRESHOLD = "start-drag-threshold"; public static final String REQUEST_SHELL_DRAG_READY = "shell-drag-ready"; Loading
tests/tapl/com/android/launcher3/tapl/LauncherInstrumentation.java +6 −0 Original line number Diff line number Diff line Loading @@ -27,6 +27,7 @@ import static android.view.MotionEvent.AXIS_GESTURE_SWIPE_FINGER_COUNT; import static com.android.launcher3.tapl.Folder.FOLDER_CONTENT_RES_ID; import static com.android.launcher3.tapl.TestHelpers.getOverviewPackageName; import static com.android.launcher3.testing.shared.TestProtocol.NORMAL_STATE_ORDINAL; import static com.android.launcher3.testing.shared.TestProtocol.REQUEST_NUM_ALL_APPS_COLUMNS; import android.app.ActivityManager; import android.app.Instrumentation; Loading Loading @@ -353,6 +354,11 @@ public final class LauncherInstrumentation { .getParcelable(TestProtocol.TEST_INFO_RESPONSE_FIELD); } public int getNumAllAppsColumns() { return getTestInfo(REQUEST_NUM_ALL_APPS_COLUMNS).getInt( TestProtocol.TEST_INFO_RESPONSE_FIELD); } public boolean isTablet() { return getTestInfo(TestProtocol.REQUEST_IS_TABLET) .getBoolean(TestProtocol.TEST_INFO_RESPONSE_FIELD); Loading