You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+25-12Lines changed: 25 additions & 12 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,11 @@
1
1
# File Manager
2
2
3
+
<imgsrc="https://i.imgur.com/NNaUK60.png"></img>
4
+
5
+

@@ -26,7 +32,7 @@ Beside needing to add WRITE_EXTERNAL_STORAGE and READ_EXTERNAL_STORAGE to your a
26
32
...
27
33
</manifest>
28
34
```
29
-
also add f0r Android 10
35
+
also add for Android 10
30
36
```
31
37
<application
32
38
android:requestLegacyExternalStorage="true"
@@ -45,7 +51,7 @@ dependencies:
45
51
46
52
### Basic setup
47
53
48
-
*The complete example is available [here](https://github.com/4-alok/draggable_home/blob/main/example/lib/main.dart).*
54
+
*The complete example is available [here](https://github.com/DevsOnFlutter/file_manager/blob/main/example/lib/main.dart).*
49
55
50
56
Required parameter for **FileManager** are `controller` and `builder`
51
57
* `controller` The controller updates value and notifies its listeners, and FileManager updates itself appropriately whenever the user modifies the path or changes the sort-type with an associated FileManagerController.
@@ -61,19 +67,19 @@ Sample code
61
67
FileManager(
62
68
controller: controller,
63
69
builder: (context, snapshot) {
64
-
final List<FileSystemEntity> entitis = snapshot;
70
+
final List<FileSystemEntity> entities = snapshot;
65
71
return ListView.builder(
66
-
itemCount: entitis.length,
72
+
itemCount: entities.length,
67
73
itemBuilder: (context, index) {
68
74
return Card(
69
75
child: ListTile(
70
-
leading: isFile(entitis[index])
76
+
leading: isFile(entities[index])
71
77
? Icon(Icons.feed_outlined)
72
78
: Icon(Icons.folder),
73
-
title: Text(basename(entitis[index])),
79
+
title: Text(basename(entities[index])),
74
80
onTap: () {
75
-
if (isDirectory(entitis[index])) {
76
-
controller.openDirectory(entitis[index]); // open directory
81
+
if (isDirectory(entities[index])) {
82
+
controller.openDirectory(entities[index]); // open directory
77
83
} else {
78
84
// Perform file-related tasks.
79
85
}
@@ -106,7 +112,7 @@ FileManager(
106
112
|`goToParentDirectory`|`goToParentDirectory` returns `bool`, goes to the parent directory of currently opened directory if the parent is accessible, return true if current directory is the root. false, if the current directory not on root of the stogare.. |
107
113
|`openDirectory`| Open directory by providing `Directory`. |
108
114
109
-
## Otheres
115
+
## Others
110
116
| Properties | Description |
111
117
|--------------|-----------------|
112
118
|`isFile`| check weather FileSystemEntity is File. |
0 commit comments