Implement better image selection strategy
This commit is contained in:
parent
a6a7c2271a
commit
4164bf36f6
19 changed files with 161 additions and 89 deletions
|
|
@ -31,6 +31,7 @@ import org.schabi.newpipe.extractor.localization.Localization;
|
|||
import org.schabi.newpipe.streams.io.NoFileManagerSafeGuard;
|
||||
import org.schabi.newpipe.streams.io.StoredFileHelper;
|
||||
import org.schabi.newpipe.util.NavigationHelper;
|
||||
import org.schabi.newpipe.util.image.ImageStrategy;
|
||||
import org.schabi.newpipe.util.image.PicassoHelper;
|
||||
import org.schabi.newpipe.util.ZipHelper;
|
||||
import org.schabi.newpipe.util.image.PreferredImageQuality;
|
||||
|
|
@ -109,7 +110,7 @@ public class ContentSettingsFragment extends BasePreferenceFragment {
|
|||
final Preference imageQualityPreference = requirePreference(R.string.image_quality_key);
|
||||
imageQualityPreference.setOnPreferenceChangeListener(
|
||||
(preference, newValue) -> {
|
||||
PicassoHelper.setPreferredImageQuality(PreferredImageQuality
|
||||
ImageStrategy.setPreferredImageQuality(PreferredImageQuality
|
||||
.fromPreferenceKey(requireContext(), (String) newValue));
|
||||
try {
|
||||
PicassoHelper.clearCache(preference.getContext());
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue