Improve Night Light suggestion criterion
Night Light suggestion will now show even if the user is using Night Light in manual mode. If the user has previously tapped or dismissed the suggestion, the suggestion will not show again. Bug: 68938869 Test: make ROBOTEST_FILTER=\ "(NightDisplayPreferenceControllerTest|SuggestionFeatureProviderImplTest)" \ RunSettingsRoboTests Change-Id: Iea838df043d75dfa73a1a383275dc42956374113
This commit is contained in:
@@ -28,6 +28,11 @@ public class NightDisplayPreferenceController extends AbstractPreferenceControll
|
||||
super(context);
|
||||
}
|
||||
|
||||
public static boolean isSuggestionComplete(Context context) {
|
||||
final ColorDisplayController controller = new ColorDisplayController(context);
|
||||
return controller.getAutoMode() != ColorDisplayController.AUTO_MODE_DISABLED;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isAvailable() {
|
||||
return ColorDisplayController.isAvailable(mContext);
|
||||
|
Reference in New Issue
Block a user