Add keywords for search terms

A large update for search keywords collected from logging
and individual feedback.

At the moment, we don't have a great way to test that a keyword
matches to a search result. It's a bit akin to testing that the
wifi title is Wifi.

Fixes: 36983488
Fixes: 36622889
Fixes: 76115241
Test: Manual audit of keywords surfacing the proper results.
Change-Id: Ia1031b7f6ec1edfcc28c07e6b55049b8dac7c685
This commit is contained in:
Matthew Fritze
2018-03-21 13:46:11 -07:00
parent 2f137b4bac
commit 5c5a921efb
12 changed files with 81 additions and 19 deletions

View File

@@ -124,7 +124,6 @@ public class DisplaySettings extends DashboardFragment {
List<String> keys = super.getNonIndexableKeys(context);
keys.add(KEY_DISPLAY_SIZE);
keys.add(WallpaperPreferenceController.KEY_WALLPAPER);
keys.add(KEY_AMBIENT_DISPLAY);
keys.add(KEY_NIGHT_DISPLAY);
return keys;
}

View File

@@ -434,6 +434,7 @@ public class BluetoothSettings extends DeviceListPreferenceFragment implements I
data.title = res.getString(R.string.bluetooth_settings);
data.screenTitle = res.getString(R.string.bluetooth_settings);
data.key = DATA_KEY_REFERENCE;
data.keywords = res.getString(R.string.keywords_bluetooth_settings);
result.add(data);
// Removed paired bluetooth device indexing. See BluetoothSettingsObsolete.java.

View File

@@ -571,6 +571,7 @@ public class StorageSettings extends SettingsPreferenceFragment implements Index
data.title = context.getString(R.string.storage_settings);
data.key = "storage_settings";
data.screenTitle = context.getString(R.string.storage_settings);
data.keywords = context.getString(R.string.keywords_storage_settings);
result.add(data);
data = new SearchIndexableRaw(context);

View File

@@ -118,6 +118,7 @@ public class WallpaperTypeSettings extends SettingsPreferenceFragment implements
data.intentAction = Intent.ACTION_SET_WALLPAPER;
data.intentTargetPackage = info.activityInfo.packageName;
data.intentTargetClass = info.activityInfo.name;
data.keywords = context.getString(R.string.keywords_wallpaper);
result.add(data);
}