A directory chooser library for Android.

Overview

Android DirectoryChooser

Build Status Gittip Maven Central Stories in Ready Android Arsenal

A simple directory chooser you can integrate into your Android app.

This version of the library has no additional dependencies, but requires Android v11+ to work. There is, however, a pre-v11-branch that supports down to v7 using ActionBarSherlock.

You can download the sample app from the Play Store:

Get it on Google Play

Based on the DirectoryChooser from the excellent AntennaPod App by danieloeh.

As stand-alone Activity
As DialogFragment

Usage

For a full example see the sample app in the repository.

From Maven Central

Library releases are available on Maven Central, snapshots can be retrieved from Sonatype:

Release (SDK 11+)

Gradle

compile 'net.rdrei.android.dirchooser:library:3.2@aar'

Maven

<dependency>
  <groupId>net.rdrei.android.dirchooser</groupId>
  <artifactId>library</artifactId>
  <version>3.2</version>
  <type>aar</type>
</dependency>

Release (SDK 7+)

Gradle

compile 'net.rdrei.android.dirchooser:library:1.0-pre-v11@aar'

Maven

<dependency>
  <groupId>net.rdrei.android.dirchooser</groupId>
  <artifactId>library</artifactId>
  <version>1.0-pre-v11</version>
  <type>aar</type>
</dependency>

Snapshot (SDK 11+)

compile 'net.rdrei.android.dirchooser:library:3.2-SNAPSHOT@aar'

Snapshot (SDK 4+)

compile 'net.rdrei.android.dirchooser:library:2.0-pre-v11-SNAPSHOT@aar'

As Library Project

Alternatively, check out this repository and add it as a library project.

$ git clone https://github.com/passy/Android-DirectoryChooser.git

Import the project into your favorite IDE and add android.library.reference.1=/path/to/Android-DirectoryChooser/library to your project.properties.

Manifest

You need to declare the DirectoryChooserActivity and request the android.permission.WRITE_EXTERNAL_STORAGE permission.

<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
...
<application>
    <activity android:name="net.rdrei.android.dirchooser.DirectoryChooserActivity" />
</application>

Activity

To choose a directory, start the activity from your app logic:

final Intent chooserIntent = new Intent(this, DirectoryChooserActivity.class);

final DirectoryChooserConfig config = DirectoryChooserConfig.builder()
        .newDirectoryName("DirChooserSample")
        .allowReadOnlyDirectory(true)
        .allowNewDirectoryNameModification(true)
        .build();

chooserIntent.putExtra(DirectoryChooserActivity.EXTRA_CONFIG, config);

// REQUEST_DIRECTORY is a constant integer to identify the request, e.g. 0
startActivityForResult(chooserIntent, REQUEST_DIRECTORY);

Handle the result in your onActivityResult method:

@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
    super.onActivityResult(requestCode, resultCode, data);

    if (requestCode == REQUEST_DIRECTORY) {
        if (resultCode == DirectoryChooserActivity.RESULT_CODE_DIR_SELECTED) {
            handleDirectoryChoice(data
                .getStringExtra(DirectoryChooserActivity.RESULT_SELECTED_DIR));
        } else {
            // Nothing selected
        }
    }
}

Fragment

You can also use the underlying DialogFragment for even better integration. Whether you use the Fragment as a Dialog or not is completely up to you. All you have to do is implement the OnFragmentInteractionListener interface to respond to the events that a directory is selected or the user cancels the dialog:

public class DirChooserFragmentSample extends Activity implements
    DirectoryChooserFragment.OnFragmentInteractionListener {

    private TextView mDirectoryTextView;
    private DirectoryChooserFragment mDialog;

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.dialog);
        final DirectoryChooserConfig config = DirectoryChooserConfig.builder()
                .newDirectoryName("DialogSample")
                .build();
        mDialog = DirectoryChooserFragment.newInstance(config);

        mDirectoryTextView = (TextView) findViewById(R.id.textDirectory);

        findViewById(R.id.btnChoose)
                .setOnClickListener(new View.OnClickListener() {
                    @Override
                    public void onClick(View v) {
                        mDialog.show(getFragmentManager(), null);
                    }
                });
    }

    @Override
    public void onSelectDirectory(@NonNull String path) {
        mDirectoryTextView.setText(path);
        mDialog.dismiss();
    }

    @Override
    public void onCancelChooser() {
        mDialog.dismiss();
    }
}

If calling the directory chooser from your own fragment, be sure to set the target fragment first:

@Override
public void onClick(View v) {
    mDialog.setTargetFragment(this, 0);
    mDialog.show(getFragmentManager(), null);
}

Configuration

The Directory Chooser is configured through a parcelable configuration object, which is great because it means that you don't have to tear your hair out over finicky string extras. Instead, you get auto-completion and a nice immutable data structure. Here's what you can configure:

newDirectoryName : String (required)

Name of the directory to create. User can change this name when he creates the folder. To avoid this use allowNewDirectoryNameModification argument.

initialDirectory : String (default: "")

Optional argument to define the path of the directory that will be shown first. If it is not sent or if path denotes a non readable/writable directory or it is not a directory, it defaults to android.os.Environment#getExternalStorageDirectory().

allowReadOnlyDirectory : Boolean (default: false)

Argument to define whether or not the directory chooser allows read-only paths to be chosen. If it false only directories with read-write access can be chosen.

allowNewDirectoryNameModification : Boolean (default: false)

Argument to define whether or not the directory chooser allows modification of provided new directory name.

Example

final DirectoryChooserConfig config = DirectoryChooserConfig.builder()
        .newDirectoryName("DialogSample")
        .allowNewDirectoryNameModification(true)
        .allowReadOnlyDirectory(true)
        .initialDirectory("/sdcard")
        .build();

Apps using this

Popcorn Time for Android
Popcorn Time for Android
Emby for Android
Emby for Android
Downloader for SoundCloud
Downloader for SoundCloud
Wallpaper Changer
Wallpaper Changer
XnRetro
XnRetro
InstaSave - Instagram Save
InstaSave
ML Manager - App manager
ML Manager
AutoGuard - Dash Cam
AutoGuard
Companion for Band
Companion for Band
Swallow Server
Swallow Server
Photo Map
Photo Map

To add your own app, please send a pull request.

Releasing

Preparation

To release a new snapshot on Maven Central, add your credentials to ~/.gradle/gradle.properties (you get them from http://oss.sonatype.org) as well as your signing GPG key:

signing.keyId=0x18EEA4AF
signing.secretKeyRingFile=/home/pascal/.gnupg/secring.gpg

NEXUS_USERNAME=username
NEXUS_PASSWORD=password

Staging

To upload a new snapshot, just run gradle's uploadArchives command:

gradle :library:uploadArchives

Release

Update versions and remove -SNAPSHOT suffixes.

gradle build :library:uploadArchives

License

Copyright 2013-2016 Pascal Hartig

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Thanks

Sample App icon by Frank Souza.

Comments
  • NoClassDefFoundError exception

    NoClassDefFoundError exception

    This happens when pressing the button with the Intent.

    final Intent chooserIntent = new Intent(context, DirectoryChooserActivity.class);
    final DirectoryChooserConfig chooserConfig = DirectoryChooserConfig.builder()
             .newDirectoryName("Dir")
             .allowReadOnlyDirectory(false)
             .allowNewDirectoryNameModification(true)
             .build();
    chooserIntent.putExtra(DirectoryChooserActivity.EXTRA_CONFIG, chooserConfig);
    startActivityForResult(chooserIntent, REQUEST_DIRECTORY);
    

    Logcat:

    08-18 17:43:11.354  27433-27433/com.javiersantos.myapp E/AndroidRuntime﹕ FATAL EXCEPTION: main
        Process: com.javiersantos.myapp, PID: 27433
        java.lang.NoClassDefFoundError: Failed resolution of: Lcom/gu/option/Option;
                at net.rdrei.android.dirchooser.DirectoryChooserFragment.<init>(DirectoryChooserFragment.java:60)
                at net.rdrei.android.dirchooser.DirectoryChooserFragment.newInstance(DirectoryChooserFragment.java:90)
                at net.rdrei.android.dirchooser.DirectoryChooserActivity.onCreate(DirectoryChooserActivity.java:38)
                at android.app.Activity.performCreate(Activity.java:5990)
                at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1106)
                at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2309)
                at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2418)
                at android.app.ActivityThread.access$900(ActivityThread.java:154)
                at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321)
                at android.os.Handler.dispatchMessage(Handler.java:102)
                at android.os.Looper.loop(Looper.java:135)
                at android.app.ActivityThread.main(ActivityThread.java:5289)
                at java.lang.reflect.Method.invoke(Native Method)
                at java.lang.reflect.Method.invoke(Method.java:372)
                at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:904)
                at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:699)
         Caused by: java.lang.ClassNotFoundException: Didn't find class "com.gu.option.Option" on path: DexPathList[[zip file "/data/app/com.javiersantos.myapp-2/base.apk"],nativeLibraryDirectories=[/vendor/lib, /system/lib]]
                at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:56)
                at java.lang.ClassLoader.loadClass(ClassLoader.java:511)
                at java.lang.ClassLoader.loadClass(ClassLoader.java:469)
                at net.rdrei.android.dirchooser.DirectoryChooserFragment.<init>(DirectoryChooserFragment.java:60)
                at net.rdrei.android.dirchooser.DirectoryChooserFragment.newInstance(DirectoryChooserFragment.java:90)
                at net.rdrei.android.dirchooser.DirectoryChooserActivity.onCreate(DirectoryChooserActivity.java:38)
                at android.app.Activity.performCreate(Activity.java:5990)
                at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1106)
                at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2309)
                at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2418)
                at android.app.ActivityThread.access$900(ActivityThread.java:154)
                at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1321)
                at android.os.Handler.dispatchMessage(Handler.java:102)
                at android.os.Looper.loop(Looper.java:135)
                at android.app.ActivityThread.main(ActivityThread.java:5289)
                at java.lang.reflect.Method.invoke(Native Method)
                at java.lang.reflect.Method.invoke(Method.java:372)
                at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:904)
                at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:699)
        Suppressed: java.lang.ClassNotFoundException: com.gu.option.Option
                at java.lang.Class.classForName(Native Method)
                at java.lang.BootClassLoader.findClass(ClassLoader.java:781)
                at java.lang.BootClassLoader.loadClass(ClassLoader.java:841)
                at java.lang.ClassLoader.loadClass(ClassLoader.java:504)
                ... 17 more
         Caused by: java.lang.NoClassDefFoundError: Class not found using the boot class loader; no stack available
    
    opened by javiersantos 19
  • Enabled skip-parent functionality to allow navigation to root fix #75

    Enabled skip-parent functionality to allow navigation to root fix #75

    Contributor checklist


    Description

    It's a rough draft to overcome limitations that one can no longer navigate higher than the root-path of the internal SD-card on current Android-Versions (>4.4, on some devices >5) as described in #75. By skipping a parent directory, that one has no access to, this functionality is restored.

    opened by apacha 12
  • Added new folder name modification feature

    Added new folder name modification feature

    I am using your library, and it works good, but i don't really understand why new folder name can not be set when creating the new folder. So I added the ability to modify new folder name when creating new folder. Library users can avoid this using boolean argument.

    opened by MajeurAndroid 9
  • Could not find com.gu:option:1.3.

    Could not find com.gu:option:1.3.

    Based off #86, since I can't use @aar, I am using compile 'net.rdrei.android.dirchooser:library:3.2' without the @aar. I get the following error, see https://github.com/guardian/Option/issues/2:

    $ gradle runDebug
    Starting a new Gradle Daemon for this build (subsequent builds will be faster).
    Configuration on demand is an incubating feature.
    
    FAILURE: Build failed with an exception.
    
    * What went wrong:
    A problem occurred configuring root project '<>'.
    > Could not resolve all dependencies for configuration ':_debugCompile'.
       > Could not find com.gu:option:1.3.
         Searched in the following locations:
             https://plugins.gradle.org/m2/com/gu/option/1.3/option-1.3.pom
             https://plugins.gradle.org/m2/com/gu/option/1.3/option-1.3.jar
             https://jitpack.io/com/gu/option/1.3/option-1.3.pom
             https://jitpack.io/com/gu/option/1.3/option-1.3.jar
             file:/<>/.m2/repository/com/gu/option/1.3/option-1.3.pom
             file:/<>/.m2/repository/com/gu/option/1.3/option-1.3.jar
             file:/<>/android-sdk/extras/android/m2repository/com/gu/option/1.3/option-1.3.pom
             file:/<>/android-sdk/extras/android/m2repository/com/gu/option/1.3/option-1.3.jar
             file:/<>/android-sdk/extras/google/m2repository/com/gu/option/1.3/option-1.3.pom
             file:/<>/android-sdk/extras/google/m2repository/com/gu/option/1.3/option-1.3.jar
         Required by:
             :<>:unspecified > net.rdrei.android.dirchooser:library:3.2
    
    * Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
    
    BUILD FAILED
    
    Total time: 8.188 secs
    

    I am forced to add maven { url 'http://guardian.github.com/maven/repo-releases' } in repositories.

    help-wanted 
    opened by jaredsburrows 7
  • Suggestion: add 'tools:replace= element at AndroidManifest.xml:18:5-65:19 to override.">

    Suggestion: add 'tools:replace="android:theme"' to element at AndroidManifest.xml:18:5-65:19 to override.

    When using compile 'net.rdrei.android.dirchooser:library:3.2@aar', remove the theme in the application manifest. Only use theme for the activity.

    :processDebugManifest
    /<>/AndroidManifest.xml:21:9-40 Error:
        Attribute application@theme value=(@style/AppTheme) from AndroidManifest.xml:21:9-40
        is also present at [net.rdrei.android.dirchooser:library:3.2] AndroidManifest.xml:9:18-62 value=(@style/DirectoryChooserTheme).
        Suggestion: add 'tools:replace="android:theme"' to <application> element at AndroidManifest.xml:18:5-65:19 to override.
    
    See http://g.co/androidstudio/manifest-merger for more information about the manifest merger.
    
    :processDebugManifest FAILED
    
    FAILURE: Build failed with an exception.
    
    * What went wrong:
    Execution failed for task ':processDebugManifest'.
    > Manifest merger failed : Attribute application@theme value=(@style/AppTheme) from AndroidManifest.xml:21:9-40
        is also present at [net.rdrei.android.dirchooser:library:3.2] AndroidManifest.xml:9:18-62 value=(@style/DirectoryChooserTheme).
        Suggestion: add 'tools:replace="android:theme"' to <application> element at AndroidManifest.xml:18:5-65:19 to override.
    
    * Try:
    Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.
    
    BUILD FAILED
    
    Total time: 0.8 secs
    
    opened by jaredsburrows 7
  • Target latest API + Material Design

    Target latest API + Material Design

    Please see https://github.com/passy/Android-DirectoryChooser/issues/54

    • Update Robolectric to 3.0-rc3 - :heavy_check_mark:
    • AppCompatv7 - Material Design - :heavy_check_mark:
    • Use testCompile for unit tests - :heavy_check_mark:
    • Remove Robolectric plugin - not needed - :heavy_check_mark:
    • Update Android gradle plugin to 1.2.3 - needed for unit tests - :heavy_check_mark:

    You will now see Material themed Fragment and Activity.

    opened by jaredsburrows 7
  • Chooser can be configured to allow read-only directories to be selected

    Chooser can be configured to allow read-only directories to be selected

    This commit is pretty simple. It adds an optional additional parameter that can be used to instruct the DirectoryChooser to allow selection of read-only directories.

    opened by OOPMan 6
  • 2.x release in maven / sonatype?

    2.x release in maven / sonatype?

    Maybe I'm looking in the wrong place but the latest releases I see in maven and sonatype are 1.0 and 1.0 respectively. Are there no 2.x releases in there?

    https://search.maven.org/#browse%7C-1536905800

    https://oss.sonatype.org/#nexus-search;quick~net.rdrei.android.dirchooser

    opened by MichaelMalony 6
  • Fix issue #88

    Fix issue #88

    Added JitPack, as com.gu.Option hasn't been updated in years, and they never pushed to JCenter or any other repo, so I used JitPack

    Contributor checklist


    Description

    opened by ParkerK 5
  • Theme used in the library conflicts with others

    Theme used in the library conflicts with others

    If you use this library you get an error that the app theme is already defined (in my own project). To fix this, you can for example add tools:replace="android:icon, android:label, android:theme, android:name" in your application tag in the manifest. However, this causes instability with other libraries such as com.daimajia.slider:library:1.1.5.

    Giving the error

    Caused by: android.view.InflateException: Binary XML file line #83: Error inflating class com.daimajia.slider.library.SliderLayout

    Is there a way to make them all work happily together?

    bug help-wanted ready 
    opened by lfdversluis 5
  • The TextView mTxtvSelectedFolder seems not to be populated.

    The TextView mTxtvSelectedFolder seems not to be populated.

    Hi! @passy

    I'm trying to use the library (2.1 version).

    All went OK but I'm hitting the following problem: The TextView showing the selected folder is not been populated and refreshed on my app. Could this be because my theme is not the native Holo? I'm using the AppCompat theme to support legacy Android versions. android:theme="@style/Theme.AppCompat"

    Or maybe it is populated but because I'm using a dark AppCompat theme the text is there but not passed to light color?

    Thanks for any advice you could give to me. Martin

    opened by martinrevert 5
  • Unresolved class in the Android Manifest

    Unresolved class in the Android Manifest

    I've tried everything and still get an error. It is an emergency; I have to finish this thing in two days. Help me, please.

    == Manifest ==

    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    
    <application
        android:allowBackup="true"
        android:dataExtractionRules="@xml/data_extraction_rules"
        android:fullBackupContent="@xml/backup_rules"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:roundIcon="@mipmap/ic_launcher_round"
        android:supportsRtl="true"
        tools:targetApi="31"
        android:theme="@style/Theme.RetryChooseDirectory">
        <activity
            android:name=".MainActivity"
            android:exported="true">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
    
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
    
            <meta-data
                android:name="android.app.lib_name"
                android:value="" />
        </activity>
    
        <activity android:name="net.rdrei.android.dirchooser.DirectoryChooserActivity"/>
    </application>
    

    == build.gradle == plugins { id 'com.android.application' }

    android { namespace 'com.example.retrychoosedirectory' compileSdk 32

    defaultConfig {
        applicationId "com.example.retrychoosedirectory"
        minSdk 26
        targetSdk 32
        versionCode 1
        versionName "1.0"
    
        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }
    
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
    

    }

    dependencies {

    implementation 'androidx.appcompat:appcompat:1.5.1'
    implementation 'com.google.android.material:material:1.7.0'
    implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
    
    implementation 'net.rdrei.android.dirchooser:library:3.2@aar'   // ...
    
    testImplementation 'junit:junit:4.13.2'
    androidTestImplementation 'androidx.test.ext:junit:1.1.4'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.0'
    

    }

    == Main Activity == package com.example.retrychoosedirectory;

    import androidx.activity.result.ActivityResult; import androidx.activity.result.ActivityResultCallback; import androidx.activity.result.ActivityResultLauncher; import androidx.activity.result.contract.ActivityResultContracts; import androidx.appcompat.app.AppCompatActivity;

    import android.content.Intent; import android.os.Bundle; import android.util.Log; import android.view.View; import android.widget.Button; import android.widget.Toast;

    import net.rdrei.android.dirchooser.DirectoryChooserActivity; import net.rdrei.android.dirchooser.DirectoryChooserConfig;

    public class MainActivity extends AppCompatActivity { // Global variable private Button clickButton; private final Intent chooserIntent = new Intent(this, DirectoryChooserActivity.class); private static final String TAG = "MainActivity"; private final DirectoryChooserConfig config = DirectoryChooserConfig.builder() .newDirectoryName("DirChooserSample") .allowReadOnlyDirectory(true) .allowNewDirectoryNameModification(true) .build();

    // Life Cycle
    @Override
    protected void onCreate(Bundle savedInstanceState)
    {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);
    
        clickButton = findViewById(R.id.button);
    
        ActivityResultLauncher<Intent> startActivityForResult = registerForActivityResult(
            new ActivityResultContracts.StartActivityForResult(),
            new ActivityResultCallback<ActivityResult>()
            {
                @Override
                public void onActivityResult(ActivityResult result)
                {
                    if(result.getResultCode() == DirectoryChooserActivity.RESULT_CODE_DIR_SELECTED)
                    {
                        Intent idk = result.getData();
                        Log.d(TAG, " >> idk = " + idk);
                    }
                }
            }
        );
    
        chooserIntent.putExtra(DirectoryChooserActivity.EXTRA_CONFIG, config);
    
        clickButton.setOnClickListener(new View.OnClickListener()
        {
            @Override
            public void onClick(View view)
            {
                startActivityForResult.launch(chooserIntent);
            }
        });
    }
    

    }

    opened by 0111101010110 0
  • Folders are not showing up

    Folders are not showing up

    Hello,

    I'm using the below code to show directories:

    Log.d("mn3m", "Internal SD Card Path: " + StorageUtils.getAllStorageLocations().get("sdCard").getAbsolutePath());
    
    Intent chooserIntent = new Intent(this, DirectoryChooserActivity.class);
    
    DirectoryChooserConfig config = DirectoryChooserConfig.builder()
                                    .newDirectoryName("DialogSample")
                                    .allowNewDirectoryNameModification(true)
                                    .allowReadOnlyDirectory(true) 
                                    .initialDirectory(StorageUtils.getAllStorageLocations()
                                                                  .get("sdCard").getAbsolutePath())
                                    .build();
    
    chooserIntent.putExtra(DirectoryChooserActivity.EXTRA_CONFIG, config);
    
    // REQUEST_DIRECTORY is a constant integer to identify the request, e.g. 0
    (chooserIntent, 10);
    

    the output of this log is:

    2020-05-09 21:50:56.546 13600-13600/pct.droid.dev D/mn3m: Internal SD Card Path: /storage/emulated/0
    

    when I use the above code, I get a new activity with EMPTY view, no directories are shown, I'm using android 10 on a OnePlus 6T device, permissions are granted and DialogChooserActivity is added in AndroidManifest.xml

    opened by abdalmoniem 1
  • Change title of DirectoryChooserActivity action bar?

    Change title of DirectoryChooserActivity action bar?

    I'm using DirectoryChooserActivity by sending an explicit intent. Is it possible to change the title of the action bar, as a parameter to DirectoryChooserConfig.builder?

    opened by nyanpasu64 0
  • Uppercase directories sorted before lowercase

    Uppercase directories sorted before lowercase

    I noticed that uppercase directories are sorted before=above lowercase directories. This feels unnatural compared to most file managers.

    If localization is not an issue (probably solvable, considering other file managers the feature working), is it possible to sort directories case-insensitively?

    It seems like sorting is performed here: https://github.com/passy/Android-DirectoryChooser/blob/ee5b7f1b4cf01598b8719fcdf8ebd066418c48f4/library/src/main/java/net/rdrei/android/dirchooser/DirectoryChooserFragment.java#L414

    https://stackoverflow.com/a/17491652

    How to sort alphabetically while ignoring case sensitive? Collections.sort(listToSort, String.CASE_INSENSITIVE_ORDER);

    opened by nyanpasu64 0
  • Unresolved class in the Android Manifest

    Unresolved class in the Android Manifest

    While adding:

    <activity android:name="net.rdrei.android.dirchooser.DirectoryChooserActivity" /> in the AndroidManifest.xml I'm getting:

    Unresolved class 'DirectoryChooserActivity'

    I've added this in my Gradle script:

    maven { url 'https://guardian.github.io/maven/repo-releases/' } under repositories; implementation 'net.rdrei.android.dirchooser:library:3.2' implementation 'com.gu:option:1.3' under dependencies.

    Is that a bug or am I missing something? I'm refactoring an old project of mine, so I'm updating all the libraries.

    opened by Pipodi 2
Releases(v3.0)
Owner
Pascal Hartig
Mobile Dev Velocity at Facebook. Ex-Tweep. Flipper by day, Haskell/Rust/PureScript by night.
Pascal Hartig
A new canvas drawing library for Android. Aims to be the Fabric.js for Android. Supports text, images, and hand/stylus drawing input. The library has a website and API docs, check it out

FabricView - A new canvas drawing library for Android. The library was born as part of a project in SD Hacks (www.sdhacks.io) on October 3rd. It is cu

Antwan Gaggi 1k Dec 13, 2022
Android StackBlur is a library that can perform a blurry effect on a Bitmap based on a gradient or radius, and return the result. The library is based on the code of Mario Klingemann.

Android StackBlur Android StackBlur is a library that can perform a blurry effect on a Bitmap based on a gradient or radius, and return the result. Th

Enrique López Mañas 3.6k Dec 29, 2022
Android library providing bread crumbs to the support library fragments.

Hansel And Gretel Android library providing bread crumbs for compatibility fragments. Usage For a working implementation of this project see the sampl

Jake Wharton 163 Nov 25, 2022
Android library used to create an awesome Android UI based on a draggable element similar to the last YouTube graphic component.

Draggable Panel DEPRECATED. This project is not maintained anymore. Draggable Panel is an Android library created to build a draggable user interface

Pedro Vicente Gómez Sánchez 3k Dec 6, 2022
TourGuide is an Android library that aims to provide an easy way to add pointers with animations over a desired Android View

TourGuide TourGuide is an Android library. It lets you add pointer, overlay and tooltip easily, guiding users on how to use your app. Refer to the exa

Tan Jun Rong 2.6k Jan 5, 2023
Bubbles for Android is an Android library to provide chat heads capabilities on your apps. With a fast way to integrate with your development.

Bubbles for Android Bubbles for Android is an Android library to provide chat heads capabilities on your apps. With a fast way to integrate with your

Txus Ballesteros 1.5k Jan 2, 2023
Wizard Pager is a library that provides an example implementation of a Wizard UI on Android, it's based of Roman Nurik's wizard pager (https://github.com/romannurik/android-wizardpager)

Wizard Pager Wizard Pager is a library that provides an example implementation of a Wizard UI on Android, it's based of Roman Nurik's wizard pager (ht

Julián Suárez 520 Nov 11, 2022
Make your native android Toasts Fancy. A library that takes the standard Android toast to the next level with a variety of styling options. Style your toast from code.

FancyToast-Android Prerequisites Add this in your root build.gradle file (not your module build.gradle file): allprojects { repositories { ... ma

Shashank Singhal 1.2k Dec 26, 2022
Make your native android Dialog Fancy. A library that takes the standard Android Dialog to the next level with a variety of styling options. Style your dialog from code.

FancyAlertDialog-Android Prerequisites Add this in your root build.gradle file (not your module build.gradle file): allprojects { repositories { ..

Shashank Singhal 350 Dec 9, 2022
A Tinder-like Android library to create the swipe cards effect. You can swipe left or right to like or dislike the content.

Swipecards Travis master: A Tinder-like cards effect as of August 2014. You can swipe left or right to like or dislike the content. The library create

Dionysis Lorentzos 2.3k Dec 9, 2022
A Material design Android pincode library. Supports Fingerprint.

LolliPin A Lollipop material design styled android pincode library (API 14+) To include in your project, add this to your build.gradle file: //Loll

Omada Health 1.6k Nov 25, 2022
Android Library to implement simple touch/tap/swipe gestures

SimpleFingerGestures An android library to implement simple 1 or 2 finger gestures easily Example Library The library is inside the libSFG folder Samp

Arnav Gupta 315 Dec 21, 2022
Useful library to use custom fonts in your android app

EasyFonts A simple and useful android library to use custom fonts in android apps without adding fonts into asset/resource folder.Also by using this l

Vijay Vankhede 419 Sep 9, 2022
Android library which allows you to swipe down from an activity to close it.

Android Sliding Activity Library Easily create activities that can slide vertically on the screen and fit well into the Material Design age. Features

Jake Klinker 1.3k Nov 25, 2022
This library provides a simple way to add a draggable sliding up panel (popularized by Google Music and Google Maps) to your Android application. Brought to you by Umano.

Note: we are not actively responding to issues right now. If you find a bug, please submit a PR. Android Sliding Up Panel This library provides a simp

Umano: News Read To You 9.4k Dec 31, 2022
An Android library supports badge notification like iOS in Samsung, LG, Sony and HTC launchers.

ShortcutBadger: The ShortcutBadger makes your Android App show the count of unread messages as a badge on your App shortcut! Supported launchers: Sony

Leo Lin 7.2k Dec 30, 2022
Android Library to build a UI Card

Card Library Travis master: Travis dev: Card Library provides an easy way to display a UI Card using the Official Google CardView in your Android app.

Gabriele Mariotti 4.7k Dec 29, 2022
A horizontal view scroller library for Android

View Flow for Android ViewFlow is an Android UI widget providing a horizontally scrollable ViewGroup with items populated from an Adapter. Scroll down

Patrik Åkerfeldt 1.8k Dec 29, 2022
[] Android library that provides a file explorer to let users select files on external storage.

aFileChooser - Android File Chooser aFileChooser is an Android Library Project that simplifies the process of presenting a file chooser on Android 2.1

Paul Burke 1.8k Jan 5, 2023