Skip to content

Commit 4a1f32e

Browse files
authored
Updated README
1 parent 3cf3bc3 commit 4a1f32e

File tree

1 file changed

+26
-4
lines changed

1 file changed

+26
-4
lines changed

README.md

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# android-folder-picker-library
22
[![Demo](https://img.shields.io/badge/Demo%20APK-2.2-blue.svg)](https://github.com/kashifo/android-folder-picker-library/releases/download/v2.2/FolderPickerDemo_v2.2.apk)
33
[![Bintray](https://img.shields.io/badge/Bintray-2.2-blue.svg)](https://bintray.com/kashifo/android-folder-picker-library/android-folder-picker-library/_latestVersion)
4-
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)
4+
[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-android--folder--picker--library-blue.svg?style=flat)](https://android-arsenal.com/details/1/5837)
55

66
A light-weight android library that can be quickly integrated into any app to let users choose folder, also files (but esp built for folders).
77

@@ -29,15 +29,18 @@ For your convenience, it is available on jCenter, So just add this in your app d
2929

3030
**To pick folder**
3131

32+
Just start FolderPicker activity from your app
3233
```java
3334
Intent intent = new Intent(this, FolderPicker.class);
34-
startActivityForResult(intent, FILEPICKER_CODE);
35+
startActivityForResult(intent, FOLDERPICKER_CODE);
3536
```
3637

38+
If the user selects folder/file, the name of folder/file will be returned to you on onActivityResult method with the variable name 'data'.
39+
3740
```java
3841

3942
protected void onActivityResult(int requestCode, int resultCode, Intent intent) {
40-
if (requestCode == FILEPICKER_CODE && resultCode == Activity.RESULT_OK) {
43+
if (requestCode == FOLDERPICKER_CODE && resultCode == Activity.RESULT_OK) {
4144

4245
String folderLocation = intent.getExtras().getString("data");
4346
Log.i( "folderLocation", folderLocation );
@@ -49,6 +52,7 @@ For your convenience, it is available on jCenter, So just add this in your app d
4952

5053
**Options**
5154

55+
Cusstomization options can be passed as extras to FolderPicker activity.
5256

5357
```java
5458

@@ -63,4 +67,22 @@ For your convenience, it is available on jCenter, So just add this in your app d
6367

6468
```
6569

66-
[Click to see an example working code](https://github.com/kashifo/android-folder-picker-library/blob/master/app/src/main/java/lib/folderpicker/demo/MainActivity.java)
70+
[Click here to see an example](https://github.com/kashifo/android-folder-picker-library/blob/master/app/src/main/java/lib/folderpicker/demo/MainActivity.java)
71+
72+
73+
## License
74+
75+
Copyright 2017 Kashif Anwaar.
76+
77+
Licensed under the Apache License, Version 2.0 (the "License");
78+
you may not use this file except in compliance with the License.
79+
You may obtain a copy of the License at
80+
81+
http://www.apache.org/licenses/LICENSE-2.0
82+
83+
Unless required by applicable law or agreed to in writing, software
84+
distributed under the License is distributed on an "AS IS" BASIS,
85+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
86+
See the License for the specific language governing permissions and
87+
limitations under the License.
88+

0 commit comments

Comments
 (0)