Merge pull request #3776 from k9mail/externalfilesdir
More clearly use getExternalFilesDir in ExternalStorageProvider
This commit is contained in:
commit
c9f3d57071
1 changed files with 2 additions and 9 deletions
|
@ -330,11 +330,6 @@ public class StorageManager {
|
|||
|
||||
private final CoreResourceProvider resourceProvider;
|
||||
|
||||
/**
|
||||
* Root of the denoted storage.
|
||||
*/
|
||||
private File mRoot;
|
||||
|
||||
/**
|
||||
* Chosen base directory.
|
||||
*/
|
||||
|
@ -352,9 +347,7 @@ public class StorageManager {
|
|||
|
||||
@Override
|
||||
public void init(Context context) {
|
||||
mRoot = Environment.getExternalStorageDirectory();
|
||||
mApplicationDirectory = new File(new File(new File(new File(mRoot, "Android"), "data"),
|
||||
context.getPackageName()), "files");
|
||||
mApplicationDirectory = context.getExternalFilesDir(null);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -384,7 +377,7 @@ public class StorageManager {
|
|||
|
||||
@Override
|
||||
public File getRoot(Context context) {
|
||||
return mRoot;
|
||||
return Environment.getExternalStorageDirectory();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue