Merge "Fix crash in non-indexable keys collection" into pi-dev am: 66e6e637a4
am: acc93635c3
Change-Id: I78aab2e3b7bc6f621e2425a88f3787e29f6ec2ff
This commit is contained in:
@@ -47,6 +47,9 @@ public class AmbientDisplayAlwaysOnPreferenceController extends TogglePreference
|
||||
|
||||
@Override
|
||||
public int getAvailabilityStatus() {
|
||||
if (mConfig == null) {
|
||||
mConfig = new AmbientDisplayConfiguration(mContext);
|
||||
}
|
||||
return isAvailable(mConfig) ? AVAILABLE : DISABLED_UNSUPPORTED;
|
||||
}
|
||||
|
||||
|
@@ -81,6 +81,9 @@ public class AmbientDisplayNotificationsPreferenceController extends
|
||||
|
||||
@Override
|
||||
public int getAvailabilityStatus() {
|
||||
if (mConfig == null) {
|
||||
mConfig = new AmbientDisplayConfiguration(mContext);
|
||||
}
|
||||
return mConfig.pulseOnNotificationAvailable() ? AVAILABLE : DISABLED_UNSUPPORTED;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user