This repository was archived by the owner on Feb 22, 2023. It is now read-only.
File tree 1 file changed +9
-9
lines changed
packages/path-provider/example/lib
1 file changed +9
-9
lines changed Original file line number Diff line number Diff line change @@ -68,8 +68,7 @@ class _MyHomePageState extends State<MyHomePage> {
68
68
69
69
void _requestExternalStorageDirectory () {
70
70
setState (() {
71
- if (Platform .operatingSystem != "ios" )
72
- _externalDocumentsDirectory = getExternalStorageDirectory ();
71
+ _externalDocumentsDirectory = getExternalStorageDirectory ();
73
72
});
74
73
}
75
74
@@ -113,16 +112,17 @@ class _MyHomePageState extends State<MyHomePage> {
113
112
child: new FutureBuilder <Directory >(
114
113
future: _appDocumentsDirectory, builder: _buildDirectory),
115
114
),
116
- new Cloumn (
115
+ new Column (
117
116
children : < Widget > [
118
117
new Padding (
119
- padding: const EdgeInserts . add (16.0 ),
118
+ padding: const EdgeInsets . all (16.0 ),
120
119
child: new RaisedButton (
121
- child: const Test ('${Platform .operatingSystem != "ios" ?
122
- "Get External Storage Directory" :
123
- "External Directories are unavailable " +
124
- "on iOS" }' ),
125
- onPressed: _requestExternalStorageDirectory,
120
+ child: new Text ('${Platform .isIOS ?
121
+ "External directories are unavailable " +
122
+ "on iOS" :
123
+ "Get External Storage Directory" }' ),
124
+ onPressed: Platform .isIOS ? null :
125
+ _requestExternalStorageDirectory,
126
126
),
127
127
),
128
128
]
You can’t perform that action at this time.
0 commit comments