From bd854ccd102d70836df45ef1778b1841d23ae19c Mon Sep 17 00:00:00 2001 From: Jason Chiu Date: Fri, 20 Nov 2020 17:16:41 +0800 Subject: [PATCH] Support contextual suggestion - add a suggestion layout - add an interface to get fragment in suggestion feature provider - remove the first preference category of homepage IA to align its top with the bottom of the search box Bug: 173768418 Test: robotest Change-Id: I784e3eef29ca474c4c89f07b916c6500fabbf7d4 --- res/layout/settings_homepage_container.xml | 37 ++++++++++- res/values/dimens.xml | 9 ++- res/values/styles.xml | 8 +++ res/xml/top_level_settings_grouped.xml | 31 ++++----- .../SuggestionFeatureProvider.java | 6 ++ .../SuggestionFeatureProviderImpl.java | 6 ++ .../homepage/SettingsHomepageActivity.java | 66 +++++++++++++++---- .../SettingsHomepageActivityTest.java | 25 +++++-- 8 files changed, 148 insertions(+), 40 deletions(-) diff --git a/res/layout/settings_homepage_container.xml b/res/layout/settings_homepage_container.xml index f210c542542..fe119c6d1e6 100644 --- a/res/layout/settings_homepage_container.xml +++ b/res/layout/settings_homepage_container.xml @@ -57,6 +57,41 @@ android:layout_height="wrap_content" android:touchscreenBlocksFocus="false" android:keyboardNavigationCluster="false"> - + + + + + + +