Fix gestures summary text when there is no sensor for assit.

Should exit the summary handling if sensor is not available.

Change-Id: I5918fa5ac614db48fc2c41e1de555d1ba6928bd4
Fix: 64039312
Test: make RunSettingsRoboTests
This commit is contained in:
Doris Ling
2017-07-26 11:07:19 -07:00
parent bd429f42cb
commit 9042f822a6
2 changed files with 13 additions and 0 deletions

View File

@@ -64,6 +64,7 @@ public class GesturesSettingPreferenceController extends AbstractPreferenceContr
public void updateState(Preference preference) {
if (!mFeatureProvider.isSensorAvailable(mContext)) {
preference.setSummary("");
return;
}
final ContentResolver contentResolver = mContext.getContentResolver();
final boolean assistGestureEnabled = Settings.Secure.getInt(