use of com.android.settingslib.dream.DreamBackend.DreamInfo in project android_packages_apps_Settings by DirtyUnicorns.
the class CurrentDreamPreferenceController method setGearClickListenerForPreference.
private void setGearClickListenerForPreference(Preference preference) {
if (!(preference instanceof GearPreference))
return;
GearPreference gearPreference = (GearPreference) preference;
Optional<DreamInfo> info = getActiveDreamInfo();
if (!info.isPresent() || info.get().settingsComponentName == null) {
gearPreference.setOnGearClickListener(null);
return;
}
gearPreference.setOnGearClickListener(gearPref -> launchScreenSaverSettings());
}
use of com.android.settingslib.dream.DreamBackend.DreamInfo in project android_packages_apps_Settings by crdroidandroid.
the class CurrentDreamPreferenceController method setGearClickListenerForPreference.
private void setGearClickListenerForPreference(Preference preference) {
if (!(preference instanceof GearPreference))
return;
GearPreference gearPreference = (GearPreference) preference;
Optional<DreamInfo> info = getActiveDreamInfo();
if (!info.isPresent() || info.get().settingsComponentName == null) {
gearPreference.setOnGearClickListener(null);
return;
}
gearPreference.setOnGearClickListener(gearPref -> launchScreenSaverSettings());
}
use of com.android.settingslib.dream.DreamBackend.DreamInfo in project android_packages_apps_Settings by SudaMod.
the class CurrentDreamPreferenceController method setGearClickListenerForPreference.
private void setGearClickListenerForPreference(Preference preference) {
if (!(preference instanceof GearPreference))
return;
GearPreference gearPreference = (GearPreference) preference;
Optional<DreamInfo> info = getActiveDreamInfo();
if (!info.isPresent() || info.get().settingsComponentName == null) {
gearPreference.setOnGearClickListener(null);
return;
}
gearPreference.setOnGearClickListener(gearPref -> launchScreenSaverSettings());
}
use of com.android.settingslib.dream.DreamBackend.DreamInfo in project Resurrection_packages_apps_Settings by ResurrectionRemix.
the class CurrentDreamPreferenceController method setGearClickListenerForPreference.
private void setGearClickListenerForPreference(Preference preference) {
if (!(preference instanceof GearPreference)) {
return;
}
final GearPreference gearPreference = (GearPreference) preference;
final Optional<DreamInfo> info = getActiveDreamInfo();
if (!info.isPresent() || info.get().settingsComponentName == null) {
gearPreference.setOnGearClickListener(null);
return;
}
gearPreference.setOnGearClickListener(gearPref -> launchScreenSaverSettings());
}
Aggregations