Search code examples
androidrestrictfile-browser

restrict AndroidFileBrowser to go up further than startdir


I want to use AndroidFileBrowser to create a simple Browser in my App. Is there a way to prevent users to go up further than the provided startDirectory I give the activity via Intent? How would I have to change the code in FileBrowserActivity.java? Thank you for your help!


Solution

  • No, this isn't implemented... You have to change the

    loadDirectoryUp()
    

    method. Just check if the current directy is the same as your "start" directory. If true, don't let the user go up a folder.