Skip to content
This repository has been archived by the owner on May 6, 2024. It is now read-only.

Commit

Permalink
Release 2.20.1
Browse files Browse the repository at this point in the history
- Disable 'Download to SD-Card' feature for OS 9 and above
  • Loading branch information
farhan committed Sep 20, 2019
1 parent 9c88c44 commit f57f535
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -100,8 +100,12 @@ public void onEventMainThread(MediaStatusChangeEvent event) {
private void updateSDCardSwitch() {
final PrefManager prefManager =
new PrefManager(getActivity().getBaseContext(), PrefManager.Pref.USER_PREF);
if (!environment.getConfig().isDownloadToSDCardEnabled() || Build.VERSION.SDK_INT <= Build.VERSION_CODES.KITKAT) {
if (!environment.getConfig().isDownloadToSDCardEnabled() ||
Build.VERSION.SDK_INT <= Build.VERSION_CODES.KITKAT ||
Build.VERSION.SDK_INT >= Build.VERSION_CODES.P
) {
sdCardSettingsLayout.setVisibility(View.GONE);
prefManager.put(PrefManager.Key.DOWNLOAD_TO_SDCARD, false);
} else {
if (!EventBus.getDefault().isRegistered(this)) {
EventBus.getDefault().registerSticky(this);
Expand Down

0 comments on commit f57f535

Please sign in to comment.