mirror of
https://github.com/revanced/revanced-integrations
synced 2024-11-27 11:13:38 +01:00
fix: sb does not turn off
This commit is contained in:
parent
a2a515d2d9
commit
97c184b5fb
@ -33,13 +33,14 @@ public class ReturnYouTubeDislikeSettingsFragment extends PreferenceFragment {
|
||||
SwitchPreference preference = new SwitchPreference(context);
|
||||
preferenceScreen.addPreference(preference);
|
||||
preference.setKey(SettingsEnum.RYD_ENABLED.getPath());
|
||||
preference.setDefaultValue(false);
|
||||
preference.setDefaultValue(SettingsEnum.RYD_ENABLED.getDefaultValue());
|
||||
preference.setChecked(SettingsEnum.RYD_ENABLED.getBoolean());
|
||||
preference.setTitle(str("revanced_ryd_title"));
|
||||
preference.setSummary(str("revanced_ryd_summary"));
|
||||
preference.setOnPreferenceChangeListener((pref, newValue) -> {
|
||||
final boolean value = (Boolean) newValue;
|
||||
ReturnYouTubeDislike.onEnabledChange(value);
|
||||
SettingsEnum.RYD_ENABLED.saveValue(value);
|
||||
return true;
|
||||
});
|
||||
}
|
||||
|
@ -66,6 +66,7 @@ public class SponsorBlockSettingsFragment extends PreferenceFragment implements
|
||||
preference.setOnPreferenceChangeListener((preference1, newValue) -> {
|
||||
final boolean value = (Boolean) newValue;
|
||||
enableCategoriesIfNeeded(value);
|
||||
SettingsEnum.SB_ENABLED.saveValue(newValue);
|
||||
return true;
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user