diff options
author | Jacobo Aragunde Pérez <jaragunde@igalia.com> | 2015-06-10 17:39:54 +0200 |
---|---|---|
committer | Jacobo Aragunde Pérez <jaragunde@igalia.com> | 2015-06-12 09:31:37 +0000 |
commit | cafae25b04d4c7cdb930a053472d6b11c1943716 (patch) | |
tree | 692d97890d76f877c1c79d573c6c8c049b2cdc36 /android | |
parent | CID#1306215 Uninitialized members (diff) | |
download | core-cafae25b04d4c7cdb930a053472d6b11c1943716.tar.gz core-cafae25b04d4c7cdb930a053472d6b11c1943716.zip |
Android: properly set default dir for the document browser
The default dir had been changing by modifying the "local documents"
provider; this is wrong because there is already a document provider
to browser de internal storage.
Change-Id: I08677283100162aaeced622153131f89abc2f1af
Reviewed-on: https://gerrit.libreoffice.org/16244
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Jacobo Aragunde Pérez <jaragunde@igalia.com>
Diffstat (limited to 'android')
-rw-r--r-- | android/source/src/java/org/libreoffice/storage/DocumentProviderFactory.java | 2 | ||||
-rw-r--r-- | android/source/src/java/org/libreoffice/storage/local/LocalDocumentsDirectoryProvider.java | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/android/source/src/java/org/libreoffice/storage/DocumentProviderFactory.java b/android/source/src/java/org/libreoffice/storage/DocumentProviderFactory.java index 612eaa6260f5..d6e4ca1671fc 100644 --- a/android/source/src/java/org/libreoffice/storage/DocumentProviderFactory.java +++ b/android/source/src/java/org/libreoffice/storage/DocumentProviderFactory.java @@ -105,7 +105,7 @@ public final class DocumentProviderFactory { * @return default provider. */ public IDocumentProvider getDefaultProvider() { - return providers[0]; + return providers[1]; } public Set<OnSharedPreferenceChangeListener> getChangeListeners() { diff --git a/android/source/src/java/org/libreoffice/storage/local/LocalDocumentsDirectoryProvider.java b/android/source/src/java/org/libreoffice/storage/local/LocalDocumentsDirectoryProvider.java index 820a915a5978..92d93d6ae075 100644 --- a/android/source/src/java/org/libreoffice/storage/local/LocalDocumentsDirectoryProvider.java +++ b/android/source/src/java/org/libreoffice/storage/local/LocalDocumentsDirectoryProvider.java @@ -28,7 +28,8 @@ public class LocalDocumentsDirectoryProvider extends LocalDocumentsProvider { @Override public IFile getRootDirectory() { File documentsDirectory = new File( - Environment.getExternalStorageDirectory(), ""); + Environment.getExternalStorageDirectory(), "Documents"); + documentsDirectory.mkdirs(); return new LocalFile(documentsDirectory); } |