Showing
88 changed files
with
4524 additions
and
0 deletions
Too many changes to show.
To preserve performance only 88 of 88+ files are displayed.
image_picker/AUTHORS
0 → 100644
1 | +# Below is a list of people and organizations that have contributed | ||
2 | +# to the Flutter project. Names should be added to the list like so: | ||
3 | +# | ||
4 | +# Name/Organization <email address> | ||
5 | + | ||
6 | +Google Inc. | ||
7 | +The Chromium Authors | ||
8 | +German Saprykin <saprykin.h@gmail.com> | ||
9 | +Benjamin Sauer <sauer.benjamin@gmail.com> | ||
10 | +larsenthomasj@gmail.com | ||
11 | +Ali Bitek <alibitek@protonmail.ch> | ||
12 | +Pol Batlló <pol.batllo@gmail.com> | ||
13 | +Anatoly Pulyaevskiy | ||
14 | +Hayden Flinner <haydenflinner@gmail.com> | ||
15 | +Stefano Rodriguez <hlsroddy@gmail.com> | ||
16 | +Salvatore Giordano <salvatoregiordanoo@gmail.com> | ||
17 | +Brian Armstrong <brian@flutter.institute> | ||
18 | +Paul DeMarco <paulmdemarco@gmail.com> | ||
19 | +Fabricio Nogueira <feufeu@gmail.com> | ||
20 | +Simon Lightfoot <simon@devangels.london> | ||
21 | +Ashton Thomas <ashton@acrinta.com> | ||
22 | +Thomas Danner <thmsdnnr@gmail.com> | ||
23 | +Diego Velásquez <diego.velasquez.lopez@gmail.com> | ||
24 | +Hajime Nakamura <nkmrhj@gmail.com> | ||
25 | +Tuyển Vũ Xuân <netsoft1985@gmail.com> | ||
26 | +Miguel Ruivo <miguel@miguelruivo.com> | ||
27 | +Sarthak Verma <sarthak@artiosys.com> | ||
28 | +Mike Diarmid <mike@invertase.io> | ||
29 | +Invertase <oss@invertase.io> | ||
30 | +Elliot Hesp <elliot@invertase.io> | ||
31 | +Vince Varga <vince.varga@smaho.com> | ||
32 | +Aawaz Gyawali <awazgyawali@gmail.com> | ||
33 | +EUI Limited <ian.evans3@admiralgroup.co.uk> | ||
34 | +Katarina Sheremet <katarina@sheremet.ch> | ||
35 | +Thomas Stockx <thomas@stockxit.com> | ||
36 | +Sarbagya Dhaubanjar <sarbagyastha@gmail.com> | ||
37 | +Ozkan Eksi <ozeksi@gmail.com> | ||
38 | +Rishab Nayak <rishab@bu.edu> | ||
39 | +ko2ic <ko2ic.dev@gmail.com> | ||
40 | +Jonathan Younger <jonathan@daikini.com> | ||
41 | +Jose Sanchez <josesm82@gmail.com> | ||
42 | +Debkanchan Samadder <debu.samadder@gmail.com> | ||
43 | +Audrius Karosevicius <audrius.karosevicius@gmail.com> | ||
44 | +Lukasz Piliszczuk <lukasz@intheloup.io> | ||
45 | +SoundReply Solutions GmbH <ch@soundreply.com> | ||
46 | +Rafal Wachol <rwachol@gmail.com> | ||
47 | +Pau Picas <pau.picas@gmail.com> | ||
48 | +Christian Weder <chrstian.weder@yapeal.ch> | ||
49 | +Alexandru Tuca <salexandru.tuca@outlook.com> | ||
50 | +Christian Weder <chrstian.weder@yapeal.ch> | ||
51 | +Rhodes Davis Jr. <rody.davis.jr@gmail.com> | ||
52 | +Luigi Agosti <luigi@tengio.com> | ||
53 | +Quentin Le Guennec <quentin@tengio.com> | ||
54 | +Koushik Ravikumar <koushik@tengio.com> | ||
55 | +Nissim Dsilva <nissim@tengio.com> | ||
56 | +Giancarlo Rocha <giancarloiff@gmail.com> | ||
57 | +Ryo Miyake <ryo@miyake.id> | ||
58 | +Théo Champion <contact.theochampion@gmail.com> | ||
59 | +Kazuki Yamaguchi <y.kazuki0614n@gmail.com> | ||
60 | +Eitan Schwartz <eshvartz@gmail.com> | ||
61 | +Chris Rutkowski <chrisrutkowski89@gmail.com> | ||
62 | +Juan Alvarez <juan.alvarez@resideo.com> | ||
63 | +Aleksandr Yurkovskiy <sanekyy@gmail.com> | ||
64 | +Anton Borries <mail@antonborri.es> | ||
65 | +Alex Li <google@alexv525.com> | ||
66 | +Rahul Raj <64.rahulraj@gmail.com> |
image_picker/CHANGELOG.md
0 → 100644
1 | +## NEXT | ||
2 | + | ||
3 | +* Updates minimum supported SDK version to Flutter 3.7/Dart 2.19. | ||
4 | + | ||
5 | +## 1.0.2 | ||
6 | + | ||
7 | +* Adds compatibility with `image_picker_for_web` 3.0. | ||
8 | + | ||
9 | +## 1.0.1 | ||
10 | + | ||
11 | +* Rolls platform implementations to ensure that `pickMedia` and | ||
12 | + `pickMultipleMedia` have platform implementations. | ||
13 | + | ||
14 | +## 1.0.0 | ||
15 | + | ||
16 | +* **BREAKING CHANGE**: Removes the deprecated `get*` methods. Clients who have | ||
17 | + not already done so will need to migrate to the `pick*` versions that use | ||
18 | + `XFile` rather than `PickedFile` for return values. | ||
19 | + * As this is the only change, we encourage authors of published packages | ||
20 | + that depend on `image_picker` to consider using a constraint of | ||
21 | + `'>=0.8.9 <2.0.0'` rather than `^1.0.0` when updating dependencies, to | ||
22 | + avoid conflicts with packages that have not yet updated. | ||
23 | + | ||
24 | +## 0.8.9 | ||
25 | + | ||
26 | +* Adds `pickMedia` and `pickMultipleMedia` methods. | ||
27 | + | ||
28 | +## 0.8.8 | ||
29 | + | ||
30 | +* Adds initial support for Windows, macOS, and Linux. | ||
31 | + * See README for current desktop limitations. | ||
32 | +* Adds `supportsImageSource` to allow runtime checks for whether a given source | ||
33 | + is supported by the current platform's implementation. | ||
34 | + | ||
35 | +## 0.8.7+5 | ||
36 | + | ||
37 | +* Fixes `BuildContext` handling in example. | ||
38 | + | ||
39 | +## 0.8.7+4 | ||
40 | + | ||
41 | +* Updates README to mention usage of `launchMode: singleInstance` for Android. | ||
42 | + | ||
43 | +## 0.8.7+3 | ||
44 | + | ||
45 | +* Adds handling of unsupported image types to the example. | ||
46 | + | ||
47 | +## 0.8.7+2 | ||
48 | + | ||
49 | +* Updates minimum Flutter version to 3.3. | ||
50 | +* Fixes a broken link in the example related to `image_picker_for_web`. | ||
51 | + | ||
52 | +## 0.8.7+1 | ||
53 | + | ||
54 | +* Updates README to use code excerpts. | ||
55 | + | ||
56 | +## 0.8.7 | ||
57 | + | ||
58 | +* Adds `usePhotoPickerAndroid` options. | ||
59 | +* Aligns Dart and Flutter SDK constraints. | ||
60 | + | ||
61 | +## 0.8.6+4 | ||
62 | + | ||
63 | +* Updates iOS minimum version in README. | ||
64 | + | ||
65 | +## 0.8.6+3 | ||
66 | + | ||
67 | +* Updates links for the merge of flutter/plugins into flutter/packages. | ||
68 | + | ||
69 | +## 0.8.6+2 | ||
70 | + | ||
71 | +* Updates `NSPhotoLibraryUsageDescription` description in README. | ||
72 | + | ||
73 | +* Updates minimum Flutter version to 3.0. | ||
74 | + | ||
75 | +## 0.8.6+1 | ||
76 | + | ||
77 | +* Updates code for stricter lint checks. | ||
78 | + | ||
79 | +## 0.8.6 | ||
80 | + | ||
81 | +* Updates minimum Flutter version to 2.10. | ||
82 | +* Fixes avoid_redundant_argument_values lint warnings and minor typos. | ||
83 | +* Adds `requestFullMetadata` option to `pickImage`, so images on iOS can be picked without `Photo Library Usage` permission. | ||
84 | + | ||
85 | +## 0.8.5+3 | ||
86 | + | ||
87 | +* Adds argument error assertions to the app-facing package, to ensure | ||
88 | + consistency across platform implementations. | ||
89 | +* Updates tests to use a mock platform instead of relying on default | ||
90 | + method channel implementation internals. | ||
91 | + | ||
92 | +## 0.8.5+2 | ||
93 | + | ||
94 | +* Minor fixes for new analysis options. | ||
95 | + | ||
96 | +## 0.8.5+1 | ||
97 | + | ||
98 | +* Fixes library_private_types_in_public_api, sort_child_properties_last and use_key_in_widget_constructors | ||
99 | + lint warnings. | ||
100 | + | ||
101 | +## 0.8.5 | ||
102 | + | ||
103 | +* Moves Android and iOS implementations to federated packages. | ||
104 | +* Adds OS version support information to README. | ||
105 | + | ||
106 | +## 0.8.4+11 | ||
107 | + | ||
108 | +* Fixes Activity leak. | ||
109 | + | ||
110 | +## 0.8.4+10 | ||
111 | + | ||
112 | +* iOS: allows picking images with WebP format. | ||
113 | + | ||
114 | +## 0.8.4+9 | ||
115 | + | ||
116 | +* Internal code cleanup for stricter analysis options. | ||
117 | + | ||
118 | +## 0.8.4+8 | ||
119 | + | ||
120 | +* Configures the `UIImagePicker` to default to gallery instead of camera when | ||
121 | +picking multiple images on pre-iOS 14 devices. | ||
122 | + | ||
123 | +## 0.8.4+7 | ||
124 | + | ||
125 | +* Refactors unit test to expose private interface via a separate test header instead of the inline declaration. | ||
126 | + | ||
127 | +## 0.8.4+6 | ||
128 | + | ||
129 | +* Fixes minor type issues in iOS implementation. | ||
130 | + | ||
131 | +## 0.8.4+5 | ||
132 | + | ||
133 | +* Improves the documentation on handling MainActivity being killed by the Android OS. | ||
134 | +* Updates Android compileSdkVersion to 31. | ||
135 | +* Fix iOS RunnerUITests search paths. | ||
136 | + | ||
137 | +## 0.8.4+4 | ||
138 | + | ||
139 | +* Fix typos in README.md. | ||
140 | + | ||
141 | +## 0.8.4+3 | ||
142 | + | ||
143 | +* Suppress a unchecked cast build warning. | ||
144 | + | ||
145 | +## 0.8.4+2 | ||
146 | + | ||
147 | +* Update minimum Flutter SDK to 2.5 and iOS deployment target to 9.0. | ||
148 | + | ||
149 | +## 0.8.4+1 | ||
150 | + | ||
151 | +* Fix README Example for `ImagePickerCache` to cache multiple files. | ||
152 | + | ||
153 | +## 0.8.4 | ||
154 | + | ||
155 | +* Update `ImagePickerCache` to cache multiple files. | ||
156 | + | ||
157 | +## 0.8.3+3 | ||
158 | + | ||
159 | +* Fix pickImage not returning a value on iOS when dismissing PHPicker sheet by swiping. | ||
160 | +* Updated Android lint settings. | ||
161 | + | ||
162 | +## 0.8.3+2 | ||
163 | + | ||
164 | +* Fix using Camera as image source on Android 11+ | ||
165 | + | ||
166 | +## 0.8.3+1 | ||
167 | + | ||
168 | +* Fixed README Example. | ||
169 | + | ||
170 | +## 0.8.3 | ||
171 | + | ||
172 | +* Move `ImagePickerFromLimitedGalleryUITests` to `RunnerUITests` target. | ||
173 | +* Improved handling of bad image data when applying metadata changes on iOS. | ||
174 | + | ||
175 | +## 0.8.2 | ||
176 | + | ||
177 | +* Added new methods that return `package:cross_file` `XFile` instances. [Docs](https://pub.dev/documentation/cross_file/latest/index.html). | ||
178 | +* Deprecate methods that return `PickedFile` instances: | ||
179 | + * `getImage`: use **`pickImage`** instead. | ||
180 | + * `getVideo`: use **`pickVideo`** instead. | ||
181 | + * `getMultiImage`: use **`pickMultiImage`** instead. | ||
182 | + * `getLostData`: use **`retrieveLostData`** instead. | ||
183 | + | ||
184 | +## 0.8.1+4 | ||
185 | + | ||
186 | +* Fixes an issue where `preferredCameraDevice` option is not working for `getVideo` method. | ||
187 | +* Refactor unit tests that were device-only before. | ||
188 | + | ||
189 | +## 0.8.1+3 | ||
190 | + | ||
191 | +* Fix image picker causing a crash when the cache directory is deleted. | ||
192 | + | ||
193 | +## 0.8.1+2 | ||
194 | + | ||
195 | +* Update the example app to support the multi-image feature. | ||
196 | + | ||
197 | +## 0.8.1+1 | ||
198 | + | ||
199 | +* Expose errors thrown in `pickImage` and `pickVideo` docs. | ||
200 | + | ||
201 | +## 0.8.1 | ||
202 | + | ||
203 | +* Add a new method `getMultiImage` to allow picking multiple images on iOS 14 or higher | ||
204 | +and Android 4.3 or higher. Returns only 1 image for lower versions of iOS and Android. | ||
205 | +* Known issue: On Android, `getLostData` will only get the last picked image when picking multiple images, | ||
206 | +see: [#84634](https://github.com/flutter/flutter/issues/84634). | ||
207 | + | ||
208 | +## 0.8.0+4 | ||
209 | + | ||
210 | +* Cleaned up the README example | ||
211 | + | ||
212 | +## 0.8.0+3 | ||
213 | + | ||
214 | +* Readded request for camera permissions. | ||
215 | + | ||
216 | +## 0.8.0+2 | ||
217 | + | ||
218 | +* Fix a rotation problem where when camera is chosen as a source and additional parameters are added. | ||
219 | + | ||
220 | +## 0.8.0+1 | ||
221 | + | ||
222 | +* Removed redundant request for camera permissions. | ||
223 | + | ||
224 | +## 0.8.0 | ||
225 | + | ||
226 | +* BREAKING CHANGE: Changed storage location for captured images and videos to internal cache on Android, | ||
227 | +to comply with new Google Play storage requirements. This means developers are responsible for moving | ||
228 | +the image or video to a different location in case more permanent storage is required. Other applications | ||
229 | +will no longer be able to access images or videos captured unless they are moved to a publicly accessible location. | ||
230 | +* Updated Mockito to fix Android tests. | ||
231 | + | ||
232 | +## 0.7.5+4 | ||
233 | +* Migrate maven repo from jcenter to mavenCentral. | ||
234 | + | ||
235 | +## 0.7.5+3 | ||
236 | +* Localize `UIAlertController` strings. | ||
237 | + | ||
238 | +## 0.7.5+2 | ||
239 | +* Implement `UIAlertController` with a preferredStyle of `UIAlertControllerStyleAlert` since `UIAlertView` is deprecated. | ||
240 | + | ||
241 | +## 0.7.5+1 | ||
242 | + | ||
243 | +* Fixes a rotation problem where Select Photos limited access is chosen but the image that is picked | ||
244 | +is not included selected photos and image is scaled. | ||
245 | + | ||
246 | +## 0.7.5 | ||
247 | + | ||
248 | +* Fixes an issue where image rotation is wrong when Select Photos chose and image is scaled. | ||
249 | +* Migrate to PHPicker for iOS 14 and higher versions to pick image from the photo library. | ||
250 | +* Implement the limited permission to pick photo from the photo library when Select Photo is chosen. | ||
251 | + | ||
252 | +## 0.7.4 | ||
253 | + | ||
254 | +* Update flutter_plugin_android_lifecycle dependency to 2.0.1 to fix an R8 issue | ||
255 | + on some versions. | ||
256 | + | ||
257 | +## 0.7.3 | ||
258 | + | ||
259 | +* Endorse image_picker_for_web. | ||
260 | + | ||
261 | +## 0.7.2+1 | ||
262 | + | ||
263 | +* Android: fixes an issue where videos could be wrongly picked with `.jpg` extension. | ||
264 | + | ||
265 | +## 0.7.2 | ||
266 | + | ||
267 | +* Run CocoaPods iOS tests in RunnerUITests target. | ||
268 | + | ||
269 | +## 0.7.1 | ||
270 | + | ||
271 | +* Update platform_plugin_interface version requirement. | ||
272 | + | ||
273 | +## 0.7.0 | ||
274 | + | ||
275 | +* Migrate to nullsafety | ||
276 | +* Breaking Changes: | ||
277 | + * Removed the deprecated methods: `ImagePicker.pickImage`, `ImagePicker.pickVideo`, | ||
278 | +`ImagePicker.retrieveLostData` | ||
279 | + | ||
280 | +## 0.6.7+22 | ||
281 | + | ||
282 | +* iOS: update XCUITests to separate each test session. | ||
283 | + | ||
284 | +## 0.6.7+21 | ||
285 | + | ||
286 | +* Update the example app: remove the deprecated `RaisedButton` and `FlatButton` widgets. | ||
287 | + | ||
288 | +## 0.6.7+20 | ||
289 | + | ||
290 | +* Updated README.md to show the new Android API requirements. | ||
291 | + | ||
292 | +## 0.6.7+19 | ||
293 | + | ||
294 | +* Do not copy static field to another static field. | ||
295 | + | ||
296 | +## 0.6.7+18 | ||
297 | + | ||
298 | +* Fix outdated links across a number of markdown files ([#3276](https://github.com/flutter/plugins/pull/3276)) | ||
299 | + | ||
300 | +## 0.6.7+17 | ||
301 | + | ||
302 | +* iOS: fix `User-facing text should use localized string macro` warning. | ||
303 | + | ||
304 | +## 0.6.7+16 | ||
305 | + | ||
306 | +* Update Flutter SDK constraint. | ||
307 | + | ||
308 | +## 0.6.7+15 | ||
309 | + | ||
310 | +* Fix element type in XCUITests to look for staticText type when searching for texts. | ||
311 | + * See https://github.com/flutter/flutter/issues/71927 | ||
312 | +* Minor update in XCUITests to search for different elements on iOS 14 and above. | ||
313 | + | ||
314 | +## 0.6.7+14 | ||
315 | + | ||
316 | +* Set up XCUITests. | ||
317 | + | ||
318 | +## 0.6.7+13 | ||
319 | + | ||
320 | +* Update documentation of `getImage()` about HEIC images. | ||
321 | + | ||
322 | +## 0.6.7+12 | ||
323 | + | ||
324 | +* Update android compileSdkVersion to 29. | ||
325 | + | ||
326 | +## 0.6.7+11 | ||
327 | + | ||
328 | +* Keep handling deprecated Android v1 classes for backward compatibility. | ||
329 | + | ||
330 | +## 0.6.7+10 | ||
331 | + | ||
332 | +* Updated documentation with code that does not throw an error when image is not picked. | ||
333 | + | ||
334 | +## 0.6.7+9 | ||
335 | + | ||
336 | +* Updated the ExifInterface to the AndroidX version to support more file formats; | ||
337 | +* Update documentation of `getImage()` regarding compression support for specific image types. | ||
338 | + | ||
339 | +## 0.6.7+8 | ||
340 | + | ||
341 | +* Update documentation of getImage() about Android's disability to preference front/rear camera. | ||
342 | + | ||
343 | +## 0.6.7+7 | ||
344 | + | ||
345 | +* Updating documentation to use isEmpty check. | ||
346 | + | ||
347 | +## 0.6.7+6 | ||
348 | + | ||
349 | +* Update package:e2e -> package:integration_test | ||
350 | + | ||
351 | +## 0.6.7+5 | ||
352 | + | ||
353 | +* Update package:e2e reference to use the local version in the flutter/plugins | ||
354 | + repository. | ||
355 | + | ||
356 | + | ||
357 | +## 0.6.7+4 | ||
358 | + | ||
359 | +* Support iOS simulator x86_64 architecture. | ||
360 | + | ||
361 | +## 0.6.7+3 | ||
362 | + | ||
363 | +* Fixes to the example app: | ||
364 | + * Make videos in web start muted. This allows auto-play across browsers. | ||
365 | + * Prevent the app from disposing of video controllers too early. | ||
366 | + | ||
367 | +## 0.6.7+2 | ||
368 | + | ||
369 | +* iOS: Fixes unpresentable album/image picker if window's root view controller is already presenting other view controller. | ||
370 | + | ||
371 | +## 0.6.7+1 | ||
372 | + | ||
373 | +* Add web support to the example app. | ||
374 | + | ||
375 | +## 0.6.7 | ||
376 | + | ||
377 | +* Utilize the new platform_interface package. | ||
378 | +* **This change marks old methods as `deprecated`. Please check the README for migration instructions to the new API.** | ||
379 | + | ||
380 | +## 0.6.6+5 | ||
381 | + | ||
382 | +* Pin the version of the platform interface to 1.0.0 until the plugin refactor | ||
383 | +is ready to go. | ||
384 | + | ||
385 | +## 0.6.6+4 | ||
386 | + | ||
387 | +* Fix bug, sometimes double click cancel button will crash. | ||
388 | + | ||
389 | +## 0.6.6+3 | ||
390 | + | ||
391 | +* Update README | ||
392 | + | ||
393 | +## 0.6.6+2 | ||
394 | + | ||
395 | +* Update lower bound of dart dependency to 2.1.0. | ||
396 | + | ||
397 | +## 0.6.6+1 | ||
398 | + | ||
399 | +* Android: always use URI to get image/video data. | ||
400 | + | ||
401 | +## 0.6.6 | ||
402 | + | ||
403 | +* Use the new platform_interface package. | ||
404 | + | ||
405 | +## 0.6.5+3 | ||
406 | + | ||
407 | +* Move core plugin to a subdirectory to allow for federation. | ||
408 | + | ||
409 | +## 0.6.5+2 | ||
410 | + | ||
411 | +* iOS: Fixes crash when an image in the gallery is tapped more than once. | ||
412 | + | ||
413 | +## 0.6.5+1 | ||
414 | + | ||
415 | +* Fix CocoaPods podspec lint warnings. | ||
416 | + | ||
417 | +## 0.6.5 | ||
418 | + | ||
419 | +* Set maximum duration for video recording. | ||
420 | +* Fix some existing XCTests. | ||
421 | + | ||
422 | +## 0.6.4 | ||
423 | + | ||
424 | +* Add a new parameter to select preferred camera device. | ||
425 | + | ||
426 | +## 0.6.3+4 | ||
427 | + | ||
428 | +* Make the pedantic dev_dependency explicit. | ||
429 | + | ||
430 | +## 0.6.3+3 | ||
431 | + | ||
432 | +* Android: Fix a crash when `externalFilesDirectory` does not exist. | ||
433 | + | ||
434 | +## 0.6.3+2 | ||
435 | + | ||
436 | +* Bump RoboElectric dependency to 4.3.1 and update resource usage. | ||
437 | + | ||
438 | +## 0.6.3+1 | ||
439 | + | ||
440 | +* Fix an issue that the example app won't launch the image picker after Android V2 embedding migration. | ||
441 | + | ||
442 | +## 0.6.3 | ||
443 | + | ||
444 | +* Support Android V2 embedding. | ||
445 | +* Migrate to using the new e2e test binding. | ||
446 | + | ||
447 | +## 0.6.2+3 | ||
448 | + | ||
449 | +* Remove the deprecated `author:` field from pubspec.yaml | ||
450 | +* Migrate the plugin to the pubspec platforms manifest. | ||
451 | +* Require Flutter SDK 1.10.0 or greater. | ||
452 | + | ||
453 | +## 0.6.2+2 | ||
454 | + | ||
455 | +* Android: Revert the image file return logic when the image doesn't have to be scaled. Fix a rotation regression caused by 0.6.2+1 | ||
456 | +* Example App: Add a dialog to enter `maxWidth`, `maxHeight` or `quality` when picking image. | ||
457 | + | ||
458 | +## 0.6.2+1 | ||
459 | + | ||
460 | +* Android: Fix a crash when a non-image file is picked. | ||
461 | +* Android: Fix unwanted bitmap scaling. | ||
462 | + | ||
463 | +## 0.6.2 | ||
464 | + | ||
465 | +* iOS: Fixes an issue where picking content from Gallery would result in a crash on iOS 13. | ||
466 | + | ||
467 | +## 0.6.1+11 | ||
468 | + | ||
469 | +* Stability and Maintainability: update documentations, add unit tests. | ||
470 | + | ||
471 | +## 0.6.1+10 | ||
472 | + | ||
473 | +* iOS: Fix image orientation problems when scaling images. | ||
474 | + | ||
475 | +## 0.6.1+9 | ||
476 | + | ||
477 | +* Remove AndroidX warning. | ||
478 | + | ||
479 | +## 0.6.1+8 | ||
480 | + | ||
481 | +* Fix iOS build and analyzer warnings. | ||
482 | + | ||
483 | +## 0.6.1+7 | ||
484 | + | ||
485 | +* Android: Fix ImagePickerPlugin#onCreate casting context which causes exception. | ||
486 | + | ||
487 | +## 0.6.1+6 | ||
488 | + | ||
489 | +* Define clang module for iOS | ||
490 | + | ||
491 | +## 0.6.1+5 | ||
492 | + | ||
493 | +* Update and migrate iOS example project. | ||
494 | + | ||
495 | +## 0.6.1+4 | ||
496 | + | ||
497 | +* Android: Fix a regression where the `retrieveLostImage` does not work anymore. | ||
498 | +* Set up Android unit test to test `ImagePickerCache` and added image quality caching tests. | ||
499 | + | ||
500 | +## 0.6.1+3 | ||
501 | + | ||
502 | +* Bugfix iOS: Fix orientation of the picked image after scaling. | ||
503 | +* Remove unnecessary code that tried to normalize the orientation. | ||
504 | +* Trivial XCTest code fix. | ||
505 | + | ||
506 | +## 0.6.1+2 | ||
507 | + | ||
508 | +* Replace dependency on `androidx.legacy:legacy-support-v4:1.0.0` with `androidx.core:core:1.0.2` | ||
509 | + | ||
510 | +## 0.6.1+1 | ||
511 | + | ||
512 | +* Add dependency on `androidx.annotation:annotation:1.0.0`. | ||
513 | + | ||
514 | +## 0.6.1 | ||
515 | + | ||
516 | +* New feature : Get images with custom quality. While picking images, user can pass `imageQuality` | ||
517 | +parameter to compress image. | ||
518 | + | ||
519 | +## 0.6.0+20 | ||
520 | + | ||
521 | +* Android: Migrated information cache methods to use instance methods. | ||
522 | + | ||
523 | +## 0.6.0+19 | ||
524 | + | ||
525 | +* Android: Fix memory leak due not unregistering ActivityLifecycleCallbacks. | ||
526 | + | ||
527 | +## 0.6.0+18 | ||
528 | + | ||
529 | +* Fix video play in example and update video_player plugin dependency. | ||
530 | + | ||
531 | +## 0.6.0+17 | ||
532 | + | ||
533 | +* iOS: Fix a crash when user captures image from the camera with devices under iOS 11. | ||
534 | + | ||
535 | +## 0.6.0+16 | ||
536 | + | ||
537 | +* iOS Simulator: fix hang after trying to take an image from the non-existent camera. | ||
538 | + | ||
539 | +## 0.6.0+15 | ||
540 | + | ||
541 | +* Android: throws an exception when permissions denied instead of ignoring. | ||
542 | + | ||
543 | +## 0.6.0+14 | ||
544 | + | ||
545 | +* Fix typo in README. | ||
546 | + | ||
547 | +## 0.6.0+13 | ||
548 | + | ||
549 | +* Bugfix Android: Fix a crash occurs in some scenarios when user picks up image from gallery. | ||
550 | + | ||
551 | +## 0.6.0+12 | ||
552 | + | ||
553 | +* Use class instead of struct for `GIFInfo` in iOS implementation. | ||
554 | + | ||
555 | +## 0.6.0+11 | ||
556 | + | ||
557 | +* Don't use module imports. | ||
558 | + | ||
559 | +## 0.6.0+10 | ||
560 | + | ||
561 | +* iOS: support picking GIF from gallery. | ||
562 | + | ||
563 | +## 0.6.0+9 | ||
564 | + | ||
565 | +* Add missing template type parameter to `invokeMethod` calls. | ||
566 | +* Bump minimum Flutter version to 1.5.0. | ||
567 | +* Replace invokeMethod with invokeMapMethod wherever necessary. | ||
568 | + | ||
569 | +## 0.6.0+8 | ||
570 | + | ||
571 | +* Bugfix: Add missed return statement into the image_picker example. | ||
572 | + | ||
573 | +## 0.6.0+7 | ||
574 | + | ||
575 | +* iOS: Rename objects to follow Objective-C naming convention to avoid conflicts with other iOS library/frameworks. | ||
576 | + | ||
577 | +## 0.6.0+6 | ||
578 | + | ||
579 | +* iOS: Picked image now has all the correct meta data from the original image, includes GPS, orientation and etc. | ||
580 | + | ||
581 | +## 0.6.0+5 | ||
582 | + | ||
583 | +* iOS: Add missing import. | ||
584 | + | ||
585 | +## 0.6.0+4 | ||
586 | + | ||
587 | +* iOS: Using first byte to determine original image type. | ||
588 | +* iOS: Added XCTest target. | ||
589 | +* iOS: The picked image now has the correct EXIF data copied from the original image. | ||
590 | + | ||
591 | +## 0.6.0+3 | ||
592 | + | ||
593 | +* Android: fixed assertion failures due to reply messages that were sent on the wrong thread. | ||
594 | + | ||
595 | +## 0.6.0+2 | ||
596 | + | ||
597 | +* Android: images are saved with their real extension instead of always using `.jpg`. | ||
598 | + | ||
599 | +## 0.6.0+1 | ||
600 | + | ||
601 | +* Android: Using correct suffix syntax when picking image from remote url. | ||
602 | + | ||
603 | +## 0.6.0 | ||
604 | + | ||
605 | +* Breaking change iOS: Returned `File` objects when picking videos now always holds the correct path. Before this change, the path returned could have `file://` prepended to it. | ||
606 | + | ||
607 | +## 0.5.4+3 | ||
608 | + | ||
609 | +* Fix the example app failing to load picked video. | ||
610 | + | ||
611 | +## 0.5.4+2 | ||
612 | + | ||
613 | +* Request Camera permission if it present in Manifest on Android >= M. | ||
614 | + | ||
615 | +## 0.5.4+1 | ||
616 | + | ||
617 | +* Bugfix iOS: Cancel button not visible in gallery, if camera was accessed first. | ||
618 | + | ||
619 | +## 0.5.4 | ||
620 | + | ||
621 | +* Add `retrieveLostData` to retrieve lost data after MainActivity is killed. | ||
622 | + | ||
623 | +## 0.5.3+2 | ||
624 | + | ||
625 | +* Android: fix a crash when the MainActivity is destroyed after selecting the image/video. | ||
626 | + | ||
627 | +## 0.5.3+1 | ||
628 | + | ||
629 | +* Update minimum deploy iOS version to 8.0. | ||
630 | + | ||
631 | +## 0.5.3 | ||
632 | + | ||
633 | +* Fixed incorrect path being returned from Google Photos on Android. | ||
634 | + | ||
635 | +## 0.5.2 | ||
636 | + | ||
637 | +* Check iOS camera authorizationStatus and return an error, if the access was | ||
638 | + denied. | ||
639 | + | ||
640 | +## 0.5.1 | ||
641 | + | ||
642 | +* Android: Do not delete original image after scaling if the image is from gallery. | ||
643 | + | ||
644 | +## 0.5.0+9 | ||
645 | + | ||
646 | +* Remove unnecessary temp video file path. | ||
647 | + | ||
648 | +## 0.5.0+8 | ||
649 | + | ||
650 | +* Fixed wrong GooglePhotos authority of image Uri. | ||
651 | + | ||
652 | +## 0.5.0+7 | ||
653 | + | ||
654 | +* Fix a crash when selecting images from yandex.disk and dropbox. | ||
655 | + | ||
656 | +## 0.5.0+6 | ||
657 | + | ||
658 | +* Delete the original image if it was scaled. | ||
659 | + | ||
660 | +## 0.5.0+5 | ||
661 | + | ||
662 | +* Remove unnecessary camera permission. | ||
663 | + | ||
664 | +## 0.5.0+4 | ||
665 | + | ||
666 | +* Preserve transparency when saving images. | ||
667 | + | ||
668 | +## 0.5.0+3 | ||
669 | + | ||
670 | +* Fixed an Android crash when Image Picker is registered without an activity. | ||
671 | + | ||
672 | +## 0.5.0+2 | ||
673 | + | ||
674 | +* Log a more detailed warning at build time about the previous AndroidX | ||
675 | + migration. | ||
676 | + | ||
677 | +## 0.5.0+1 | ||
678 | + | ||
679 | +* Fix a crash when user calls the plugin in quick succession on Android. | ||
680 | + | ||
681 | +## 0.5.0 | ||
682 | + | ||
683 | +* **Breaking change**. Migrate from the deprecated original Android Support | ||
684 | + Library to AndroidX. This shouldn't result in any functional changes, but it | ||
685 | + requires any Android apps using this plugin to [also | ||
686 | + migrate](https://developer.android.com/jetpack/androidx/migrate) if they're | ||
687 | + using the original support library. | ||
688 | + | ||
689 | +## 0.4.12+1 | ||
690 | + | ||
691 | +* Fix a crash when selecting downloaded images from image picker on certain devices. | ||
692 | + | ||
693 | +## 0.4.12 | ||
694 | + | ||
695 | +* Fix a crash when user tap the image mutiple times. | ||
696 | + | ||
697 | +## 0.4.11 | ||
698 | + | ||
699 | +* Use `api` to define `support-v4` dependency to allow automatic version resolution. | ||
700 | + | ||
701 | +## 0.4.10 | ||
702 | + | ||
703 | +* Depend on full `support-v4` library for ease of use (fixes conflicts with Firebase and libraries) | ||
704 | + | ||
705 | +## 0.4.9 | ||
706 | + | ||
707 | +* Bugfix: on iOS prevent to appear one pixel white line on resized image. | ||
708 | + | ||
709 | +## 0.4.8 | ||
710 | + | ||
711 | +* Replace the full `com.android.support:appcompat-v7` dependency with `com.android.support:support-core-utils`, which results in smaller APK sizes. | ||
712 | +* Upgrade support library to 27.1.1 | ||
713 | + | ||
714 | +## 0.4.7 | ||
715 | + | ||
716 | +* Added missing video_player package dev dependency. | ||
717 | + | ||
718 | +## 0.4.6 | ||
719 | + | ||
720 | +* Added support for picking remote images. | ||
721 | + | ||
722 | +## 0.4.5 | ||
723 | + | ||
724 | +* Bugfixes, code cleanup, more test coverage. | ||
725 | + | ||
726 | +## 0.4.4 | ||
727 | + | ||
728 | +* Updated Gradle tooling to match Android Studio 3.1.2. | ||
729 | + | ||
730 | +## 0.4.3 | ||
731 | + | ||
732 | +* Bugfix: on iOS the `pickVideo` method will now return null when the user cancels picking a video. | ||
733 | + | ||
734 | +## 0.4.2 | ||
735 | + | ||
736 | +* Added support for picking videos. | ||
737 | +* Updated example app to show video preview. | ||
738 | + | ||
739 | +## 0.4.1 | ||
740 | + | ||
741 | +* Bugfix: the `pickImage` method will now return null when the user cancels picking the image, instead of hanging indefinitely. | ||
742 | +* Removed the third party library dependency for taking pictures with the camera. | ||
743 | + | ||
744 | +## 0.4.0 | ||
745 | + | ||
746 | +* **Breaking change**. The `source` parameter for the `pickImage` is now required. Also, the `ImageSource.any` option doesn't exist anymore. | ||
747 | +* Use the native Android image gallery for picking images instead of a custom UI. | ||
748 | + | ||
749 | +## 0.3.1 | ||
750 | + | ||
751 | +* Bugfix: Android version correctly asks for runtime camera permission when using `ImageSource.camera`. | ||
752 | + | ||
753 | +## 0.3.0 | ||
754 | + | ||
755 | +* **Breaking change**. Set SDK constraints to match the Flutter beta release. | ||
756 | + | ||
757 | +## 0.2.1 | ||
758 | + | ||
759 | +* Simplified and upgraded Android project template to Android SDK 27. | ||
760 | +* Updated package description. | ||
761 | + | ||
762 | +## 0.2.0 | ||
763 | + | ||
764 | +* **Breaking change**. Upgraded to Gradle 4.1 and Android Studio Gradle plugin | ||
765 | + 3.0.1. Older Flutter projects need to upgrade their Gradle setup as well in | ||
766 | + order to use this version of the plugin. Instructions can be found | ||
767 | + [here](https://github.com/flutter/flutter/wiki/Updating-Flutter-projects-to-Gradle-4.1-and-Android-Studio-Gradle-plugin-3.0.1). | ||
768 | + | ||
769 | +## 0.1.5 | ||
770 | + | ||
771 | +* Added FLT prefix to iOS types | ||
772 | + | ||
773 | +## 0.1.4 | ||
774 | + | ||
775 | +* Bugfix: canceling image picking threw exception. | ||
776 | +* Bugfix: errors in plugin state management. | ||
777 | + | ||
778 | +## 0.1.3 | ||
779 | + | ||
780 | +* Added optional source argument to pickImage for controlling where the image comes from. | ||
781 | + | ||
782 | +## 0.1.2 | ||
783 | + | ||
784 | +* Added optional maxWidth and maxHeight arguments to pickImage. | ||
785 | + | ||
786 | +## 0.1.1 | ||
787 | + | ||
788 | +* Updated Gradle repositories declaration to avoid the need for manual configuration | ||
789 | + in the consuming app. | ||
790 | + | ||
791 | +## 0.1.0+1 | ||
792 | + | ||
793 | +* Updated readme and description in pubspec.yaml | ||
794 | + | ||
795 | +## 0.1.0 | ||
796 | + | ||
797 | +* Updated dependencies | ||
798 | +* **Breaking Change**: You need to add a maven section with the "https://maven.google.com" endpoint to the repository section of your `android/build.gradle`. For example: | ||
799 | +```gradle | ||
800 | +allprojects { | ||
801 | + repositories { | ||
802 | + jcenter() | ||
803 | + maven { // NEW | ||
804 | + url "https://maven.google.com" // NEW | ||
805 | + } // NEW | ||
806 | + } | ||
807 | +} | ||
808 | +``` | ||
809 | + | ||
810 | +## 0.0.3 | ||
811 | + | ||
812 | +* Fix for crash on iPad when showing the Camera/Gallery selection dialog | ||
813 | + | ||
814 | +## 0.0.2+2 | ||
815 | + | ||
816 | +* Updated README | ||
817 | + | ||
818 | +## 0.0.2+1 | ||
819 | + | ||
820 | +* Updated README | ||
821 | + | ||
822 | +## 0.0.2 | ||
823 | + | ||
824 | +* Fix crash when trying to access camera on a device without camera (e.g. the Simulator) | ||
825 | + | ||
826 | +## 0.0.1 | ||
827 | + | ||
828 | +* Initial Release |
image_picker/LICENSE
0 → 100644
1 | +image_picker | ||
2 | + | ||
3 | +Copyright 2013 The Flutter Authors. All rights reserved. | ||
4 | + | ||
5 | +Redistribution and use in source and binary forms, with or without modification, | ||
6 | +are permitted provided that the following conditions are met: | ||
7 | + | ||
8 | + * Redistributions of source code must retain the above copyright | ||
9 | + notice, this list of conditions and the following disclaimer. | ||
10 | + * Redistributions in binary form must reproduce the above | ||
11 | + copyright notice, this list of conditions and the following | ||
12 | + disclaimer in the documentation and/or other materials provided | ||
13 | + with the distribution. | ||
14 | + * Neither the name of Google Inc. nor the names of its | ||
15 | + contributors may be used to endorse or promote products derived | ||
16 | + from this software without specific prior written permission. | ||
17 | + | ||
18 | +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND | ||
19 | +ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED | ||
20 | +WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE | ||
21 | +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR | ||
22 | +ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES | ||
23 | +(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; | ||
24 | +LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON | ||
25 | +ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | ||
26 | +(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS | ||
27 | +SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | ||
28 | +-------------------------------------------------------------------------------- | ||
29 | +aFileChooser | ||
30 | + | ||
31 | + Apache License | ||
32 | + Version 2.0, January 2004 | ||
33 | + http://www.apache.org/licenses/ | ||
34 | + | ||
35 | + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION | ||
36 | + | ||
37 | + 1. Definitions. | ||
38 | + | ||
39 | + "License" shall mean the terms and conditions for use, reproduction, | ||
40 | + and distribution as defined by Sections 1 through 9 of this document. | ||
41 | + | ||
42 | + "Licensor" shall mean the copyright owner or entity authorized by | ||
43 | + the copyright owner that is granting the License. | ||
44 | + | ||
45 | + "Legal Entity" shall mean the union of the acting entity and all | ||
46 | + other entities that control, are controlled by, or are under common | ||
47 | + control with that entity. For the purposes of this definition, | ||
48 | + "control" means (i) the power, direct or indirect, to cause the | ||
49 | + direction or management of such entity, whether by contract or | ||
50 | + otherwise, or (ii) ownership of fifty percent (50%) or more of the | ||
51 | + outstanding shares, or (iii) beneficial ownership of such entity. | ||
52 | + | ||
53 | + "You" (or "Your") shall mean an individual or Legal Entity | ||
54 | + exercising permissions granted by this License. | ||
55 | + | ||
56 | + "Source" form shall mean the preferred form for making modifications, | ||
57 | + including but not limited to software source code, documentation | ||
58 | + source, and configuration files. | ||
59 | + | ||
60 | + "Object" form shall mean any form resulting from mechanical | ||
61 | + transformation or translation of a Source form, including but | ||
62 | + not limited to compiled object code, generated documentation, | ||
63 | + and conversions to other media types. | ||
64 | + | ||
65 | + "Work" shall mean the work of authorship, whether in Source or | ||
66 | + Object form, made available under the License, as indicated by a | ||
67 | + copyright notice that is included in or attached to the work | ||
68 | + (an example is provided in the Appendix below). | ||
69 | + | ||
70 | + "Derivative Works" shall mean any work, whether in Source or Object | ||
71 | + form, that is based on (or derived from) the Work and for which the | ||
72 | + editorial revisions, annotations, elaborations, or other modifications | ||
73 | + represent, as a whole, an original work of authorship. For the purposes | ||
74 | + of this License, Derivative Works shall not include works that remain | ||
75 | + separable from, or merely link (or bind by name) to the interfaces of, | ||
76 | + the Work and Derivative Works thereof. | ||
77 | + | ||
78 | + "Contribution" shall mean any work of authorship, including | ||
79 | + the original version of the Work and any modifications or additions | ||
80 | + to that Work or Derivative Works thereof, that is intentionally | ||
81 | + submitted to Licensor for inclusion in the Work by the copyright owner | ||
82 | + or by an individual or Legal Entity authorized to submit on behalf of | ||
83 | + the copyright owner. For the purposes of this definition, "submitted" | ||
84 | + means any form of electronic, verbal, or written communication sent | ||
85 | + to the Licensor or its representatives, including but not limited to | ||
86 | + communication on electronic mailing lists, source code control systems, | ||
87 | + and issue tracking systems that are managed by, or on behalf of, the | ||
88 | + Licensor for the purpose of discussing and improving the Work, but | ||
89 | + excluding communication that is conspicuously marked or otherwise | ||
90 | + designated in writing by the copyright owner as "Not a Contribution." | ||
91 | + | ||
92 | + "Contributor" shall mean Licensor and any individual or Legal Entity | ||
93 | + on behalf of whom a Contribution has been received by Licensor and | ||
94 | + subsequently incorporated within the Work. | ||
95 | + | ||
96 | + 2. Grant of Copyright License. Subject to the terms and conditions of | ||
97 | + this License, each Contributor hereby grants to You a perpetual, | ||
98 | + worldwide, non-exclusive, no-charge, royalty-free, irrevocable | ||
99 | + copyright license to reproduce, prepare Derivative Works of, | ||
100 | + publicly display, publicly perform, sublicense, and distribute the | ||
101 | + Work and such Derivative Works in Source or Object form. | ||
102 | + | ||
103 | + 3. Grant of Patent License. Subject to the terms and conditions of | ||
104 | + this License, each Contributor hereby grants to You a perpetual, | ||
105 | + worldwide, non-exclusive, no-charge, royalty-free, irrevocable | ||
106 | + (except as stated in this section) patent license to make, have made, | ||
107 | + use, offer to sell, sell, import, and otherwise transfer the Work, | ||
108 | + where such license applies only to those patent claims licensable | ||
109 | + by such Contributor that are necessarily infringed by their | ||
110 | + Contribution(s) alone or by combination of their Contribution(s) | ||
111 | + with the Work to which such Contribution(s) was submitted. If You | ||
112 | + institute patent litigation against any entity (including a | ||
113 | + cross-claim or counterclaim in a lawsuit) alleging that the Work | ||
114 | + or a Contribution incorporated within the Work constitutes direct | ||
115 | + or contributory patent infringement, then any patent licenses | ||
116 | + granted to You under this License for that Work shall terminate | ||
117 | + as of the date such litigation is filed. | ||
118 | + | ||
119 | + 4. Redistribution. You may reproduce and distribute copies of the | ||
120 | + Work or Derivative Works thereof in any medium, with or without | ||
121 | + modifications, and in Source or Object form, provided that You | ||
122 | + meet the following conditions: | ||
123 | + | ||
124 | + (a) You must give any other recipients of the Work or | ||
125 | + Derivative Works a copy of this License; and | ||
126 | + | ||
127 | + (b) You must cause any modified files to carry prominent notices | ||
128 | + stating that You changed the files; and | ||
129 | + | ||
130 | + (c) You must retain, in the Source form of any Derivative Works | ||
131 | + that You distribute, all copyright, patent, trademark, and | ||
132 | + attribution notices from the Source form of the Work, | ||
133 | + excluding those notices that do not pertain to any part of | ||
134 | + the Derivative Works; and | ||
135 | + | ||
136 | + (d) If the Work includes a "NOTICE" text file as part of its | ||
137 | + distribution, then any Derivative Works that You distribute must | ||
138 | + include a readable copy of the attribution notices contained | ||
139 | + within such NOTICE file, excluding those notices that do not | ||
140 | + pertain to any part of the Derivative Works, in at least one | ||
141 | + of the following places: within a NOTICE text file distributed | ||
142 | + as part of the Derivative Works; within the Source form or | ||
143 | + documentation, if provided along with the Derivative Works; or, | ||
144 | + within a display generated by the Derivative Works, if and | ||
145 | + wherever such third-party notices normally appear. The contents | ||
146 | + of the NOTICE file are for informational purposes only and | ||
147 | + do not modify the License. You may add Your own attribution | ||
148 | + notices within Derivative Works that You distribute, alongside | ||
149 | + or as an addendum to the NOTICE text from the Work, provided | ||
150 | + that such additional attribution notices cannot be construed | ||
151 | + as modifying the License. | ||
152 | + | ||
153 | + You may add Your own copyright statement to Your modifications and | ||
154 | + may provide additional or different license terms and conditions | ||
155 | + for use, reproduction, or distribution of Your modifications, or | ||
156 | + for any such Derivative Works as a whole, provided Your use, | ||
157 | + reproduction, and distribution of the Work otherwise complies with | ||
158 | + the conditions stated in this License. | ||
159 | + | ||
160 | + 5. Submission of Contributions. Unless You explicitly state otherwise, | ||
161 | + any Contribution intentionally submitted for inclusion in the Work | ||
162 | + by You to the Licensor shall be under the terms and conditions of | ||
163 | + this License, without any additional terms or conditions. | ||
164 | + Notwithstanding the above, nothing herein shall supersede or modify | ||
165 | + the terms of any separate license agreement you may have executed | ||
166 | + with Licensor regarding such Contributions. | ||
167 | + | ||
168 | + 6. Trademarks. This License does not grant permission to use the trade | ||
169 | + names, trademarks, service marks, or product names of the Licensor, | ||
170 | + except as required for reasonable and customary use in describing the | ||
171 | + origin of the Work and reproducing the content of the NOTICE file. | ||
172 | + | ||
173 | + 7. Disclaimer of Warranty. Unless required by applicable law or | ||
174 | + agreed to in writing, Licensor provides the Work (and each | ||
175 | + Contributor provides its Contributions) on an "AS IS" BASIS, | ||
176 | + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or | ||
177 | + implied, including, without limitation, any warranties or conditions | ||
178 | + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A | ||
179 | + PARTICULAR PURPOSE. You are solely responsible for determining the | ||
180 | + appropriateness of using or redistributing the Work and assume any | ||
181 | + risks associated with Your exercise of permissions under this License. | ||
182 | + | ||
183 | + 8. Limitation of Liability. In no event and under no legal theory, | ||
184 | + whether in tort (including negligence), contract, or otherwise, | ||
185 | + unless required by applicable law (such as deliberate and grossly | ||
186 | + negligent acts) or agreed to in writing, shall any Contributor be | ||
187 | + liable to You for damages, including any direct, indirect, special, | ||
188 | + incidental, or consequential damages of any character arising as a | ||
189 | + result of this License or out of the use or inability to use the | ||
190 | + Work (including but not limited to damages for loss of goodwill, | ||
191 | + work stoppage, computer failure or malfunction, or any and all | ||
192 | + other commercial damages or losses), even if such Contributor | ||
193 | + has been advised of the possibility of such damages. | ||
194 | + | ||
195 | + 9. Accepting Warranty or Additional Liability. While redistributing | ||
196 | + the Work or Derivative Works thereof, You may choose to offer, | ||
197 | + and charge a fee for, acceptance of support, warranty, indemnity, | ||
198 | + or other liability obligations and/or rights consistent with this | ||
199 | + License. However, in accepting such obligations, You may act only | ||
200 | + on Your own behalf and on Your sole responsibility, not on behalf | ||
201 | + of any other Contributor, and only if You agree to indemnify, | ||
202 | + defend, and hold each Contributor harmless for any liability | ||
203 | + incurred by, or claims asserted against, such Contributor by reason | ||
204 | + of your accepting any such warranty or additional liability. | ||
205 | + | ||
206 | + END OF TERMS AND CONDITIONS | ||
207 | + | ||
208 | + APPENDIX: How to apply the Apache License to your work. | ||
209 | + | ||
210 | + To apply the Apache License to your work, attach the following | ||
211 | + boilerplate notice, with the fields enclosed by brackets "[]" | ||
212 | + replaced with your own identifying information. (Don't include | ||
213 | + the brackets!) The text should be enclosed in the appropriate | ||
214 | + comment syntax for the file format. We also recommend that a | ||
215 | + file or class name and description of purpose be included on the | ||
216 | + same "printed page" as the copyright notice for easier | ||
217 | + identification within third-party archives. | ||
218 | + | ||
219 | + Copyright 2011 - 2013 Paul Burke | ||
220 | + | ||
221 | + Licensed under the Apache License, Version 2.0 (the "License"); | ||
222 | + you may not use this file except in compliance with the License. | ||
223 | + You may obtain a copy of the License at | ||
224 | + | ||
225 | + http://www.apache.org/licenses/LICENSE-2.0 | ||
226 | + | ||
227 | + Unless required by applicable law or agreed to in writing, software | ||
228 | + distributed under the License is distributed on an "AS IS" BASIS, | ||
229 | + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
230 | + See the License for the specific language governing permissions and | ||
231 | + limitations under the License. |
image_picker/README.md
0 → 100644
1 | +# Image Picker plugin for Flutter | ||
2 | +<?code-excerpt path-base="example/lib"?> | ||
3 | + | ||
4 | +[](https://pub.dev/packages/image_picker) | ||
5 | + | ||
6 | +A Flutter plugin for iOS and Android for picking images from the image library, | ||
7 | +and taking new pictures with the camera. | ||
8 | + | ||
9 | +| | Android | iOS | Linux | macOS | Web | Windows | | ||
10 | +|-------------|---------|---------|-------|--------|---------------------------------|-------------| | ||
11 | +| **Support** | SDK 21+ | iOS 11+ | Any | 10.14+ | [See `image_picker_for_web`][1] | Windows 10+ | | ||
12 | + | ||
13 | +## Installation | ||
14 | + | ||
15 | +First, add `image_picker` as a | ||
16 | +[dependency in your pubspec.yaml file](https://flutter.dev/docs/development/platform-integration/platform-channels). | ||
17 | + | ||
18 | +### iOS | ||
19 | + | ||
20 | +Starting with version **0.8.1** the iOS implementation uses PHPicker to pick | ||
21 | +(multiple) images on iOS 14 or higher. | ||
22 | +As a result of implementing PHPicker it becomes impossible to pick HEIC images | ||
23 | +on the iOS simulator in iOS 14+. This is a known issue. Please test this on a | ||
24 | +real device, or test with non-HEIC images until Apple solves this issue. | ||
25 | +[63426347 - Apple known issue](https://www.google.com/search?q=63426347+apple&sxsrf=ALeKk01YnTMid5S0PYvhL8GbgXJ40ZS[…]t=gws-wiz&ved=0ahUKEwjKh8XH_5HwAhWL_rsIHUmHDN8Q4dUDCA8&uact=5) | ||
26 | + | ||
27 | +Add the following keys to your _Info.plist_ file, located in | ||
28 | +`<project root>/ios/Runner/Info.plist`: | ||
29 | + | ||
30 | +* `NSPhotoLibraryUsageDescription` - describe why your app needs permission for | ||
31 | +the photo library. This is called _Privacy - Photo Library Usage Description_ in | ||
32 | +the visual editor. | ||
33 | + * This permission will not be requested if you always pass `false` for | ||
34 | + `requestFullMetadata`, but App Store policy requires including the plist | ||
35 | + entry. | ||
36 | +* `NSCameraUsageDescription` - describe why your app needs access to the camera. | ||
37 | +This is called _Privacy - Camera Usage Description_ in the visual editor. | ||
38 | +* `NSMicrophoneUsageDescription` - describe why your app needs access to the | ||
39 | +microphone, if you intend to record videos. This is called | ||
40 | +_Privacy - Microphone Usage Description_ in the visual editor. | ||
41 | + | ||
42 | +### Android | ||
43 | + | ||
44 | +Starting with version **0.8.1** the Android implementation support to pick | ||
45 | +(multiple) images on Android 4.3 or higher. | ||
46 | + | ||
47 | +No configuration required - the plugin should work out of the box. It is however | ||
48 | +highly recommended to prepare for Android killing the application when low on memory. How to prepare for this is discussed in the | ||
49 | +[Handling MainActivity destruction on Android](#handling-mainactivity-destruction) | ||
50 | +section. | ||
51 | + | ||
52 | +It is no longer required to add `android:requestLegacyExternalStorage="true"` as | ||
53 | +an attribute to the `<application>` tag in AndroidManifest.xml, as | ||
54 | +`image_picker` has been updated to make use of scoped storage. | ||
55 | + | ||
56 | +#### Handling MainActivity destruction | ||
57 | + | ||
58 | +When under high memory pressure the Android system may kill the MainActivity of | ||
59 | +the application using the image_picker. On Android the image_picker makes use | ||
60 | +of the default `Intent.ACTION_GET_CONTENT` or `MediaStore.ACTION_IMAGE_CAPTURE` | ||
61 | +intents. This means that while the intent is executing the source application | ||
62 | +is moved to the background and becomes eligible for cleanup when the system is | ||
63 | +low on memory. When the intent finishes executing, Android will restart the | ||
64 | +application. Since the data is never returned to the original call use the | ||
65 | +`ImagePicker.retrieveLostData()` method to retrieve the lost data. For example: | ||
66 | + | ||
67 | +<?code-excerpt "readme_excerpts.dart (LostData)"?> | ||
68 | +```dart | ||
69 | +Future<void> getLostData() async { | ||
70 | + final ImagePicker picker = ImagePicker(); | ||
71 | + final LostDataResponse response = await picker.retrieveLostData(); | ||
72 | + if (response.isEmpty) { | ||
73 | + return; | ||
74 | + } | ||
75 | + final List<XFile>? files = response.files; | ||
76 | + if (files != null) { | ||
77 | + _handleLostFiles(files); | ||
78 | + } else { | ||
79 | + _handleError(response.exception); | ||
80 | + } | ||
81 | +} | ||
82 | +``` | ||
83 | + | ||
84 | +This check should always be run at startup in order to detect and handle this | ||
85 | +case. Please refer to the | ||
86 | +[example app](https://pub.dev/packages/image_picker/example) for a more complete | ||
87 | +example of handling this flow. | ||
88 | + | ||
89 | +#### Permanently storing images and videos | ||
90 | + | ||
91 | +Images and videos picked using the camera are saved to your application's local | ||
92 | +cache, and should therefore be expected to only be around temporarily. | ||
93 | +If you require your picked image to be stored permanently, it is your | ||
94 | +responsibility to move it to a more permanent location. | ||
95 | + | ||
96 | +#### Android Photo Picker | ||
97 | + | ||
98 | +This package has optional | ||
99 | +[Android Photo Picker](https://developer.android.com/training/data-storage/shared/photopicker) | ||
100 | +functionality. | ||
101 | +[Learn how to use it](https://pub.dev/packages/image_picker_android). | ||
102 | + | ||
103 | +#### Using `launchMode: singleInstance` | ||
104 | + | ||
105 | +Launching the image picker from an `Activity` with `launchMode: singleInstance` | ||
106 | +will always return `RESULT_CANCELED`. | ||
107 | +In this launch mode, new activities are created in a separate [Task][2]. | ||
108 | +As activities cannot communicate between tasks, the image picker activity cannot | ||
109 | +send back its eventual result to the calling activity. | ||
110 | +To work around this problem, consider using `launchMode: singleTask` instead. | ||
111 | + | ||
112 | +### Windows, macOS, and Linux | ||
113 | + | ||
114 | +This plugin currently has limited support for the three desktop platforms, | ||
115 | +serving as a wrapper around the [`file_selector`](https://pub.dev/packages/file_selector) | ||
116 | +plugin with appropriate file type filters set. Selection modification options, | ||
117 | +such as max width and height, are not yet supported. | ||
118 | + | ||
119 | +By default, `ImageSource.camera` is not supported, since unlike on Android and | ||
120 | +iOS there is no system-provided UI for taking photos. However, the desktop | ||
121 | +implementations allow delegating to a camera handler by setting a | ||
122 | +`cameraDelegate` before using `image_picker`, such as in `main()`: | ||
123 | + | ||
124 | +<?code-excerpt "readme_excerpts.dart (CameraDelegate)"?> | ||
125 | +```dart | ||
126 | +import 'package:image_picker_platform_interface/image_picker_platform_interface.dart'; | ||
127 | +// ··· | ||
128 | +class MyCameraDelegate extends ImagePickerCameraDelegate { | ||
129 | + @override | ||
130 | + Future<XFile?> takePhoto( | ||
131 | + {ImagePickerCameraDelegateOptions options = | ||
132 | + const ImagePickerCameraDelegateOptions()}) async { | ||
133 | + return _takeAPhoto(options.preferredCameraDevice); | ||
134 | + } | ||
135 | + | ||
136 | + @override | ||
137 | + Future<XFile?> takeVideo( | ||
138 | + {ImagePickerCameraDelegateOptions options = | ||
139 | + const ImagePickerCameraDelegateOptions()}) async { | ||
140 | + return _takeAVideo(options.preferredCameraDevice); | ||
141 | + } | ||
142 | +} | ||
143 | +// ··· | ||
144 | +void setUpCameraDelegate() { | ||
145 | + final ImagePickerPlatform instance = ImagePickerPlatform.instance; | ||
146 | + if (instance is CameraDelegatingImagePickerPlatform) { | ||
147 | + instance.cameraDelegate = MyCameraDelegate(); | ||
148 | + } | ||
149 | +} | ||
150 | +``` | ||
151 | + | ||
152 | +Once you have set a `cameraDelegate`, `image_picker` calls with | ||
153 | +`ImageSource.camera` will work as normal, calling your provided delegate. We | ||
154 | +encourage the community to build packages that implement | ||
155 | +`ImagePickerCameraDelegate`, to provide options for desktop camera UI. | ||
156 | + | ||
157 | +#### macOS installation | ||
158 | + | ||
159 | +Since the macOS implementation uses `file_selector`, you will need to | ||
160 | +add a filesystem access | ||
161 | +[entitlement][https://docs.flutter.dev/platform-integration/macos/building#entitlements-and-the-app-sandbox]: | ||
162 | +```xml | ||
163 | + <key>com.apple.security.files.user-selected.read-only</key> | ||
164 | + <true/> | ||
165 | +``` | ||
166 | + | ||
167 | +### Example | ||
168 | + | ||
169 | +<?code-excerpt "readme_excerpts.dart (Pick)"?> | ||
170 | +```dart | ||
171 | +final ImagePicker picker = ImagePicker(); | ||
172 | +// Pick an image. | ||
173 | +final XFile? image = await picker.pickImage(source: ImageSource.gallery); | ||
174 | +// Capture a photo. | ||
175 | +final XFile? photo = await picker.pickImage(source: ImageSource.camera); | ||
176 | +// Pick a video. | ||
177 | +final XFile? galleryVideo = | ||
178 | + await picker.pickVideo(source: ImageSource.gallery); | ||
179 | +// Capture a video. | ||
180 | +final XFile? cameraVideo = await picker.pickVideo(source: ImageSource.camera); | ||
181 | +// Pick multiple images. | ||
182 | +final List<XFile> images = await picker.pickMultiImage(); | ||
183 | +// Pick singe image or video. | ||
184 | +final XFile? media = await picker.pickMedia(); | ||
185 | +// Pick multiple images and videos. | ||
186 | +final List<XFile> medias = await picker.pickMultipleMedia(); | ||
187 | +``` | ||
188 | + | ||
189 | +## Migrating to 1.0 | ||
190 | + | ||
191 | +Starting with version 0.8.2 of the image_picker plugin, new methods were | ||
192 | +added that return `XFile` instances (from the | ||
193 | +[cross_file](https://pub.dev/packages/cross_file) package) rather than the | ||
194 | +plugin's own `PickedFile` instances. The previous methods were supported through | ||
195 | +0.8.9, and removed in 1.0.0. | ||
196 | + | ||
197 | +#### Call the new methods | ||
198 | + | ||
199 | +| Old API | New API | | ||
200 | +|---------|---------| | ||
201 | +| `PickedFile image = await _picker.getImage(...)` | `XFile image = await _picker.pickImage(...)` | | ||
202 | +| `List<PickedFile> images = await _picker.getMultiImage(...)` | `List<XFile> images = await _picker.pickMultiImage(...)` | | ||
203 | +| `PickedFile video = await _picker.getVideo(...)` | `XFile video = await _picker.pickVideo(...)` | | ||
204 | +| `LostData response = await _picker.getLostData()` | `LostDataResponse response = await _picker.retrieveLostData()` | | ||
205 | + | ||
206 | +[1]: https://pub.dev/packages/image_picker_for_web#limitations-on-the-web-platform | ||
207 | +[2]: https://developer.android.com/guide/components/activities/tasks-and-back-stack |
image_picker/example/README.md
0 → 100644
1 | +def localProperties = new Properties() | ||
2 | +def localPropertiesFile = rootProject.file('local.properties') | ||
3 | +if (localPropertiesFile.exists()) { | ||
4 | + localPropertiesFile.withReader('UTF-8') { reader -> | ||
5 | + localProperties.load(reader) | ||
6 | + } | ||
7 | +} | ||
8 | + | ||
9 | +def flutterRoot = localProperties.getProperty('flutter.sdk') | ||
10 | +if (flutterRoot == null) { | ||
11 | + throw new GradleException("Flutter SDK not found. Define location with flutter.sdk in the local.properties file.") | ||
12 | +} | ||
13 | + | ||
14 | +def flutterVersionCode = localProperties.getProperty('flutter.versionCode') | ||
15 | +if (flutterVersionCode == null) { | ||
16 | + flutterVersionCode = '1' | ||
17 | +} | ||
18 | + | ||
19 | +def flutterVersionName = localProperties.getProperty('flutter.versionName') | ||
20 | +if (flutterVersionName == null) { | ||
21 | + flutterVersionName = '1.0' | ||
22 | +} | ||
23 | + | ||
24 | +apply plugin: 'com.android.application' | ||
25 | +apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" | ||
26 | + | ||
27 | +android { | ||
28 | + namespace 'io.flutter.plugins.imagepickerexample' | ||
29 | + compileSdkVersion flutter.compileSdkVersion | ||
30 | + testOptions.unitTests.includeAndroidResources = true | ||
31 | + | ||
32 | + | ||
33 | + defaultConfig { | ||
34 | + applicationId "io.flutter.plugins.imagepicker.example" | ||
35 | + minSdkVersion flutter.minSdkVersion | ||
36 | + targetSdkVersion 28 | ||
37 | + multiDexEnabled true | ||
38 | + versionCode flutterVersionCode.toInteger() | ||
39 | + versionName flutterVersionName | ||
40 | + testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" | ||
41 | + } | ||
42 | + | ||
43 | + buildTypes { | ||
44 | + release { | ||
45 | + // TODO: Add your own signing config for the release build. | ||
46 | + // Signing with the debug keys for now, so `flutter run --release` works. | ||
47 | + signingConfig signingConfigs.debug | ||
48 | + } | ||
49 | + } | ||
50 | + lint { | ||
51 | + disable 'InvalidPackage' | ||
52 | + } | ||
53 | + | ||
54 | + testOptions { | ||
55 | + unitTests.returnDefaultValues = true | ||
56 | + } | ||
57 | +} | ||
58 | + | ||
59 | +flutter { | ||
60 | + source '../..' | ||
61 | +} | ||
62 | + | ||
63 | +dependencies { | ||
64 | + testImplementation 'junit:junit:4.13.2' | ||
65 | + androidTestImplementation 'androidx.test:runner:1.2.0' | ||
66 | + androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' | ||
67 | + api 'androidx.test:core:1.2.0' | ||
68 | +} |
image_picker/example/android/app/src/androidTest/java/io/flutter/plugins/DartIntegrationTest.java
0 → 100644
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +package io.flutter.plugins; | ||
6 | + | ||
7 | +import java.lang.annotation.ElementType; | ||
8 | +import java.lang.annotation.Retention; | ||
9 | +import java.lang.annotation.RetentionPolicy; | ||
10 | +import java.lang.annotation.Target; | ||
11 | + | ||
12 | +/* | ||
13 | + * Annotation to aid repository tooling in determining if a test is | ||
14 | + * a native java unit test or a java class with a dart integration. | ||
15 | + * | ||
16 | + * See: https://github.com/flutter/flutter/wiki/Plugin-Tests#enabling-android-ui-tests | ||
17 | + * for more infomation. | ||
18 | + */ | ||
19 | +@Retention(RetentionPolicy.RUNTIME) | ||
20 | +@Target(ElementType.TYPE) | ||
21 | +public @interface DartIntegrationTest {} |
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +package io.flutter.plugins.imagepickerexample; | ||
6 | + | ||
7 | +import androidx.test.rule.ActivityTestRule; | ||
8 | +import dev.flutter.plugins.integration_test.FlutterTestRunner; | ||
9 | +import io.flutter.embedding.android.FlutterActivity; | ||
10 | +import io.flutter.plugins.DartIntegrationTest; | ||
11 | +import org.junit.Rule; | ||
12 | +import org.junit.runner.RunWith; | ||
13 | + | ||
14 | +@DartIntegrationTest | ||
15 | +@RunWith(FlutterTestRunner.class) | ||
16 | +public class FlutterActivityTest { | ||
17 | + @Rule | ||
18 | + public ActivityTestRule<FlutterActivity> rule = new ActivityTestRule<>(FlutterActivity.class); | ||
19 | +} |
1 | +<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
2 | + package="io.flutter.plugins.imagepickerexample"> | ||
3 | + <!-- Flutter needs internet permission to communicate with the running application | ||
4 | + to allow setting breakpoints, to provide hot reload, etc. | ||
5 | + --> | ||
6 | + <uses-permission android:name="android.permission.INTERNET"/> | ||
7 | + <application android:usesCleartextTraffic="true"> | ||
8 | + <activity | ||
9 | + android:name=".ImagePickerTestActivity" | ||
10 | + android:launchMode="singleTop" | ||
11 | + android:theme="@android:style/Theme.Black.NoTitleBar" | ||
12 | + android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode" | ||
13 | + android:hardwareAccelerated="true" | ||
14 | + android:windowSoftInputMode="adjustResize"> | ||
15 | + </activity> | ||
16 | + </application> | ||
17 | +</manifest> |
1 | +<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
2 | + package="io.flutter.plugins.imagepickerexample"> | ||
3 | + | ||
4 | + <uses-permission android:name="android.permission.INTERNET"/> | ||
5 | + | ||
6 | + <application android:label="Image Picker Example" android:icon="@mipmap/ic_launcher"> | ||
7 | + <activity android:name="io.flutter.embedding.android.FlutterActivity" | ||
8 | + android:theme="@android:style/Theme.Black.NoTitleBar" | ||
9 | + android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection" | ||
10 | + android:hardwareAccelerated="true" | ||
11 | + android:windowSoftInputMode="adjustResize"> | ||
12 | + <intent-filter> | ||
13 | + <action android:name="android.intent.action.MAIN"/> | ||
14 | + <category android:name="android.intent.category.LAUNCHER"/> | ||
15 | + </intent-filter> | ||
16 | + </activity> | ||
17 | + <meta-data android:name="flutterEmbedding" android:value="2"/> | ||
18 | + </application> | ||
19 | +</manifest> |
1 | +GeneratedPluginRegistrant.java |
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +package io.flutter.plugins.imagepickerexample; | ||
6 | + | ||
7 | +import androidx.annotation.NonNull; | ||
8 | +import io.flutter.embedding.android.FlutterActivity; | ||
9 | +import io.flutter.embedding.engine.FlutterEngine; | ||
10 | + | ||
11 | +// Makes the FlutterEngine accessible for testing. | ||
12 | +public class ImagePickerTestActivity extends FlutterActivity { | ||
13 | + public FlutterEngine engine; | ||
14 | + | ||
15 | + @Override | ||
16 | + public void configureFlutterEngine(@NonNull FlutterEngine flutterEngine) { | ||
17 | + super.configureFlutterEngine(flutterEngine); | ||
18 | + engine = flutterEngine; | ||
19 | + } | ||
20 | +} |

544 Bytes

442 Bytes

721 Bytes

1.01 KB

1.41 KB
image_picker/example/android/build.gradle
0 → 100644
1 | +buildscript { | ||
2 | + repositories { | ||
3 | + google() | ||
4 | + mavenCentral() | ||
5 | + } | ||
6 | + | ||
7 | + dependencies { | ||
8 | + classpath 'com.android.tools.build:gradle:7.4.2' | ||
9 | + } | ||
10 | +} | ||
11 | + | ||
12 | +allprojects { | ||
13 | + repositories { | ||
14 | + // See https://github.com/flutter/flutter/wiki/Plugins-and-Packages-repository-structure#gradle-structure for more info. | ||
15 | + def artifactRepoKey = 'ARTIFACT_HUB_REPOSITORY' | ||
16 | + if (System.getenv().containsKey(artifactRepoKey)) { | ||
17 | + println "Using artifact hub" | ||
18 | + maven { url System.getenv(artifactRepoKey) } | ||
19 | + } | ||
20 | + google() | ||
21 | + mavenCentral() | ||
22 | + } | ||
23 | +} | ||
24 | + | ||
25 | +rootProject.buildDir = '../build' | ||
26 | +subprojects { | ||
27 | + project.buildDir = "${rootProject.buildDir}/${project.name}" | ||
28 | +} | ||
29 | +subprojects { | ||
30 | + project.evaluationDependsOn(':app') | ||
31 | +} | ||
32 | + | ||
33 | +tasks.register("clean", Delete) { | ||
34 | + delete rootProject.buildDir | ||
35 | +} |
image_picker/example/android/settings.gradle
0 → 100644
1 | +include ':app' | ||
2 | + | ||
3 | +def flutterProjectRoot = rootProject.projectDir.parentFile.toPath() | ||
4 | + | ||
5 | +def plugins = new Properties() | ||
6 | +def pluginsFile = new File(flutterProjectRoot.toFile(), '.flutter-plugins') | ||
7 | +if (pluginsFile.exists()) { | ||
8 | + pluginsFile.withInputStream { stream -> plugins.load(stream) } | ||
9 | +} | ||
10 | + | ||
11 | +plugins.each { name, path -> | ||
12 | + def pluginDirectory = flutterProjectRoot.resolve(path).resolve('android').toFile() | ||
13 | + include ":$name" | ||
14 | + project(":$name").projectDir = pluginDirectory | ||
15 | +} | ||
16 | + | ||
17 | +// See https://github.com/flutter/flutter/wiki/Plugins-and-Packages-repository-structure#gradle-structure for more info. | ||
18 | +buildscript { | ||
19 | + repositories { | ||
20 | + maven { | ||
21 | + url "https://plugins.gradle.org/m2/" | ||
22 | + } | ||
23 | + } | ||
24 | + dependencies { | ||
25 | + classpath "gradle.plugin.com.google.cloud.artifactregistry:artifactregistry-gradle-plugin:2.2.1" | ||
26 | + } | ||
27 | +} | ||
28 | +apply plugin: "com.google.cloud.artifactregistry.gradle-plugin" |
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +import 'package:flutter_test/flutter_test.dart'; | ||
6 | +import 'package:integration_test/integration_test.dart'; | ||
7 | + | ||
8 | +void main() { | ||
9 | + IntegrationTestWidgetsFlutterBinding.ensureInitialized(); | ||
10 | + | ||
11 | + testWidgets('placeholder test', (WidgetTester tester) async {}); | ||
12 | +} |
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
3 | +<plist version="1.0"> | ||
4 | +<dict> | ||
5 | + <key>CFBundleDevelopmentRegion</key> | ||
6 | + <string>en</string> | ||
7 | + <key>CFBundleExecutable</key> | ||
8 | + <string>App</string> | ||
9 | + <key>CFBundleIdentifier</key> | ||
10 | + <string>io.flutter.flutter.app</string> | ||
11 | + <key>CFBundleInfoDictionaryVersion</key> | ||
12 | + <string>6.0</string> | ||
13 | + <key>CFBundleName</key> | ||
14 | + <string>App</string> | ||
15 | + <key>CFBundlePackageType</key> | ||
16 | + <string>FMWK</string> | ||
17 | + <key>CFBundleShortVersionString</key> | ||
18 | + <string>1.0</string> | ||
19 | + <key>CFBundleSignature</key> | ||
20 | + <string>????</string> | ||
21 | + <key>CFBundleVersion</key> | ||
22 | + <string>1.0</string> | ||
23 | + <key>UIRequiredDeviceCapabilities</key> | ||
24 | + <array> | ||
25 | + <string>arm64</string> | ||
26 | + </array> | ||
27 | + <key>MinimumOSVersion</key> | ||
28 | + <string>11.0</string> | ||
29 | +</dict> | ||
30 | +</plist> |
image_picker/example/ios/Podfile
0 → 100644
1 | +# Uncomment this line to define a global platform for your project | ||
2 | +# platform :ios, '11.0' | ||
3 | + | ||
4 | +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. | ||
5 | +ENV['COCOAPODS_DISABLE_STATS'] = 'true' | ||
6 | + | ||
7 | +project 'Runner', { | ||
8 | + 'Debug' => :debug, | ||
9 | + 'Profile' => :release, | ||
10 | + 'Release' => :release, | ||
11 | +} | ||
12 | + | ||
13 | +def flutter_root | ||
14 | + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'Generated.xcconfig'), __FILE__) | ||
15 | + unless File.exist?(generated_xcode_build_settings_path) | ||
16 | + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure flutter pub get is executed first" | ||
17 | + end | ||
18 | + | ||
19 | + File.foreach(generated_xcode_build_settings_path) do |line| | ||
20 | + matches = line.match(/FLUTTER_ROOT\=(.*)/) | ||
21 | + return matches[1].strip if matches | ||
22 | + end | ||
23 | + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Generated.xcconfig, then run flutter pub get" | ||
24 | +end | ||
25 | + | ||
26 | +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) | ||
27 | + | ||
28 | +flutter_ios_podfile_setup | ||
29 | + | ||
30 | +target 'Runner' do | ||
31 | + flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__)) | ||
32 | +end | ||
33 | + | ||
34 | +post_install do |installer| | ||
35 | + installer.pods_project.targets.each do |target| | ||
36 | + flutter_additional_ios_build_settings(target) | ||
37 | + end | ||
38 | +end |
1 | +// !$*UTF8*$! | ||
2 | +{ | ||
3 | + archiveVersion = 1; | ||
4 | + classes = { | ||
5 | + }; | ||
6 | + objectVersion = 54; | ||
7 | + objects = { | ||
8 | + | ||
9 | +/* Begin PBXBuildFile section */ | ||
10 | + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */ = {isa = PBXBuildFile; fileRef = 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */; }; | ||
11 | + 5C9513011EC38BD300040975 /* GeneratedPluginRegistrant.m in Sources */ = {isa = PBXBuildFile; fileRef = 5C9513001EC38BD300040975 /* GeneratedPluginRegistrant.m */; }; | ||
12 | + 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */; }; | ||
13 | + 97C146F31CF9000F007C117D /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 97C146F21CF9000F007C117D /* main.m */; }; | ||
14 | + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FA1CF9000F007C117D /* Main.storyboard */; }; | ||
15 | + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */; }; | ||
16 | + 9FC8F0E9229FA49E00C8D58F /* gifImage.gif in Resources */ = {isa = PBXBuildFile; fileRef = 9FC8F0E8229FA49E00C8D58F /* gifImage.gif */; }; | ||
17 | + F4F7A436CCA4BF276270A3AE /* libPods-Runner.a in Frameworks */ = {isa = PBXBuildFile; fileRef = EC32F6993F4529982D9519F1 /* libPods-Runner.a */; }; | ||
18 | +/* End PBXBuildFile section */ | ||
19 | + | ||
20 | +/* Begin PBXCopyFilesBuildPhase section */ | ||
21 | + 9705A1C41CF9048500538489 /* Embed Frameworks */ = { | ||
22 | + isa = PBXCopyFilesBuildPhase; | ||
23 | + buildActionMask = 2147483647; | ||
24 | + dstPath = ""; | ||
25 | + dstSubfolderSpec = 10; | ||
26 | + files = ( | ||
27 | + ); | ||
28 | + name = "Embed Frameworks"; | ||
29 | + runOnlyForDeploymentPostprocessing = 0; | ||
30 | + }; | ||
31 | +/* End PBXCopyFilesBuildPhase section */ | ||
32 | + | ||
33 | +/* Begin PBXFileReference section */ | ||
34 | + 0C7B151765FD4249454C49AD /* Pods-RunnerTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.release.xcconfig"; path = "Pods/Target Support Files/Pods-RunnerTests/Pods-RunnerTests.release.xcconfig"; sourceTree = "<group>"; }; | ||
35 | + 35AE65F25E0B8C8214D8372B /* libPods-RunnerTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-RunnerTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; | ||
36 | + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = AppFrameworkInfo.plist; path = Flutter/AppFrameworkInfo.plist; sourceTree = "<group>"; }; | ||
37 | + 5A9D31B91557877A0E8EF3E7 /* Pods-Runner.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.release.xcconfig"; path = "Pods/Target Support Files/Pods-Runner/Pods-Runner.release.xcconfig"; sourceTree = "<group>"; }; | ||
38 | + 5C9512FF1EC38BD300040975 /* GeneratedPluginRegistrant.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = GeneratedPluginRegistrant.h; sourceTree = "<group>"; }; | ||
39 | + 5C9513001EC38BD300040975 /* GeneratedPluginRegistrant.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = GeneratedPluginRegistrant.m; sourceTree = "<group>"; }; | ||
40 | + 680049352280F2B8006DD6AB /* pngImage.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; path = pngImage.png; sourceTree = "<group>"; }; | ||
41 | + 680049362280F2B8006DD6AB /* jpgImage.jpg */ = {isa = PBXFileReference; lastKnownFileType = image.jpeg; path = jpgImage.jpg; sourceTree = "<group>"; }; | ||
42 | + 6801632E632668F4349764C9 /* Pods-Runner.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-Runner.debug.xcconfig"; path = "Pods/Target Support Files/Pods-Runner/Pods-Runner.debug.xcconfig"; sourceTree = "<group>"; }; | ||
43 | + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = Release.xcconfig; path = Flutter/Release.xcconfig; sourceTree = "<group>"; }; | ||
44 | + 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = "<group>"; }; | ||
45 | + 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = "<group>"; }; | ||
46 | + 86E9A88F272747B90017E6E0 /* webpImage.webp */ = {isa = PBXFileReference; lastKnownFileType = file; path = webpImage.webp; sourceTree = "<group>"; }; | ||
47 | + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Debug.xcconfig; path = Flutter/Debug.xcconfig; sourceTree = "<group>"; }; | ||
48 | + 9740EEB31CF90195004384FC /* Generated.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; name = Generated.xcconfig; path = Flutter/Generated.xcconfig; sourceTree = "<group>"; }; | ||
49 | + 97C146EE1CF9000F007C117D /* Runner.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = Runner.app; sourceTree = BUILT_PRODUCTS_DIR; }; | ||
50 | + 97C146F21CF9000F007C117D /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = "<group>"; }; | ||
51 | + 97C146FB1CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = "<group>"; }; | ||
52 | + 97C146FD1CF9000F007C117D /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = "<group>"; }; | ||
53 | + 97C147001CF9000F007C117D /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = "<group>"; }; | ||
54 | + 97C147021CF9000F007C117D /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = "<group>"; }; | ||
55 | + 9FC8F0E8229FA49E00C8D58F /* gifImage.gif */ = {isa = PBXFileReference; lastKnownFileType = image.gif; path = gifImage.gif; sourceTree = "<group>"; }; | ||
56 | + DC6FCAAD4E7580C9B3C2E21D /* Pods-RunnerTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-RunnerTests.debug.xcconfig"; path = "Pods/Target Support Files/Pods-RunnerTests/Pods-RunnerTests.debug.xcconfig"; sourceTree = "<group>"; }; | ||
57 | + EC32F6993F4529982D9519F1 /* libPods-Runner.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-Runner.a"; sourceTree = BUILT_PRODUCTS_DIR; }; | ||
58 | +/* End PBXFileReference section */ | ||
59 | + | ||
60 | +/* Begin PBXFrameworksBuildPhase section */ | ||
61 | + 97C146EB1CF9000F007C117D /* Frameworks */ = { | ||
62 | + isa = PBXFrameworksBuildPhase; | ||
63 | + buildActionMask = 2147483647; | ||
64 | + files = ( | ||
65 | + F4F7A436CCA4BF276270A3AE /* libPods-Runner.a in Frameworks */, | ||
66 | + ); | ||
67 | + runOnlyForDeploymentPostprocessing = 0; | ||
68 | + }; | ||
69 | +/* End PBXFrameworksBuildPhase section */ | ||
70 | + | ||
71 | +/* Begin PBXGroup section */ | ||
72 | + 680049282280E33D006DD6AB /* TestImages */ = { | ||
73 | + isa = PBXGroup; | ||
74 | + children = ( | ||
75 | + 86E9A88F272747B90017E6E0 /* webpImage.webp */, | ||
76 | + 9FC8F0E8229FA49E00C8D58F /* gifImage.gif */, | ||
77 | + 680049362280F2B8006DD6AB /* jpgImage.jpg */, | ||
78 | + 680049352280F2B8006DD6AB /* pngImage.png */, | ||
79 | + ); | ||
80 | + path = TestImages; | ||
81 | + sourceTree = "<group>"; | ||
82 | + }; | ||
83 | + 840012C8B5EDBCF56B0E4AC1 /* Pods */ = { | ||
84 | + isa = PBXGroup; | ||
85 | + children = ( | ||
86 | + 6801632E632668F4349764C9 /* Pods-Runner.debug.xcconfig */, | ||
87 | + 5A9D31B91557877A0E8EF3E7 /* Pods-Runner.release.xcconfig */, | ||
88 | + DC6FCAAD4E7580C9B3C2E21D /* Pods-RunnerTests.debug.xcconfig */, | ||
89 | + 0C7B151765FD4249454C49AD /* Pods-RunnerTests.release.xcconfig */, | ||
90 | + ); | ||
91 | + name = Pods; | ||
92 | + sourceTree = "<group>"; | ||
93 | + }; | ||
94 | + 9740EEB11CF90186004384FC /* Flutter */ = { | ||
95 | + isa = PBXGroup; | ||
96 | + children = ( | ||
97 | + 3B3967151E833CAA004F5970 /* AppFrameworkInfo.plist */, | ||
98 | + 9740EEB21CF90195004384FC /* Debug.xcconfig */, | ||
99 | + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, | ||
100 | + 9740EEB31CF90195004384FC /* Generated.xcconfig */, | ||
101 | + ); | ||
102 | + name = Flutter; | ||
103 | + sourceTree = "<group>"; | ||
104 | + }; | ||
105 | + 97C146E51CF9000F007C117D = { | ||
106 | + isa = PBXGroup; | ||
107 | + children = ( | ||
108 | + 680049282280E33D006DD6AB /* TestImages */, | ||
109 | + 9740EEB11CF90186004384FC /* Flutter */, | ||
110 | + 97C146F01CF9000F007C117D /* Runner */, | ||
111 | + 97C146EF1CF9000F007C117D /* Products */, | ||
112 | + 840012C8B5EDBCF56B0E4AC1 /* Pods */, | ||
113 | + CF3B75C9A7D2FA2A4C99F110 /* Frameworks */, | ||
114 | + ); | ||
115 | + sourceTree = "<group>"; | ||
116 | + }; | ||
117 | + 97C146EF1CF9000F007C117D /* Products */ = { | ||
118 | + isa = PBXGroup; | ||
119 | + children = ( | ||
120 | + 97C146EE1CF9000F007C117D /* Runner.app */, | ||
121 | + ); | ||
122 | + name = Products; | ||
123 | + sourceTree = "<group>"; | ||
124 | + }; | ||
125 | + 97C146F01CF9000F007C117D /* Runner */ = { | ||
126 | + isa = PBXGroup; | ||
127 | + children = ( | ||
128 | + 5C9512FF1EC38BD300040975 /* GeneratedPluginRegistrant.h */, | ||
129 | + 5C9513001EC38BD300040975 /* GeneratedPluginRegistrant.m */, | ||
130 | + 7AFFD8ED1D35381100E5BB4D /* AppDelegate.h */, | ||
131 | + 7AFFD8EE1D35381100E5BB4D /* AppDelegate.m */, | ||
132 | + 97C146FA1CF9000F007C117D /* Main.storyboard */, | ||
133 | + 97C146FD1CF9000F007C117D /* Assets.xcassets */, | ||
134 | + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */, | ||
135 | + 97C147021CF9000F007C117D /* Info.plist */, | ||
136 | + 97C146F11CF9000F007C117D /* Supporting Files */, | ||
137 | + ); | ||
138 | + path = Runner; | ||
139 | + sourceTree = "<group>"; | ||
140 | + }; | ||
141 | + 97C146F11CF9000F007C117D /* Supporting Files */ = { | ||
142 | + isa = PBXGroup; | ||
143 | + children = ( | ||
144 | + 97C146F21CF9000F007C117D /* main.m */, | ||
145 | + ); | ||
146 | + name = "Supporting Files"; | ||
147 | + sourceTree = "<group>"; | ||
148 | + }; | ||
149 | + CF3B75C9A7D2FA2A4C99F110 /* Frameworks */ = { | ||
150 | + isa = PBXGroup; | ||
151 | + children = ( | ||
152 | + EC32F6993F4529982D9519F1 /* libPods-Runner.a */, | ||
153 | + 35AE65F25E0B8C8214D8372B /* libPods-RunnerTests.a */, | ||
154 | + ); | ||
155 | + name = Frameworks; | ||
156 | + sourceTree = "<group>"; | ||
157 | + }; | ||
158 | +/* End PBXGroup section */ | ||
159 | + | ||
160 | +/* Begin PBXNativeTarget section */ | ||
161 | + 97C146ED1CF9000F007C117D /* Runner */ = { | ||
162 | + isa = PBXNativeTarget; | ||
163 | + buildConfigurationList = 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */; | ||
164 | + buildPhases = ( | ||
165 | + AB1344B0443C71CD721E1BB7 /* [CP] Check Pods Manifest.lock */, | ||
166 | + 9740EEB61CF901F6004384FC /* Run Script */, | ||
167 | + 97C146EA1CF9000F007C117D /* Sources */, | ||
168 | + 97C146EB1CF9000F007C117D /* Frameworks */, | ||
169 | + 97C146EC1CF9000F007C117D /* Resources */, | ||
170 | + 9705A1C41CF9048500538489 /* Embed Frameworks */, | ||
171 | + 3B06AD1E1E4923F5004D2608 /* Thin Binary */, | ||
172 | + ); | ||
173 | + buildRules = ( | ||
174 | + ); | ||
175 | + dependencies = ( | ||
176 | + ); | ||
177 | + name = Runner; | ||
178 | + productName = Runner; | ||
179 | + productReference = 97C146EE1CF9000F007C117D /* Runner.app */; | ||
180 | + productType = "com.apple.product-type.application"; | ||
181 | + }; | ||
182 | +/* End PBXNativeTarget section */ | ||
183 | + | ||
184 | +/* Begin PBXProject section */ | ||
185 | + 97C146E61CF9000F007C117D /* Project object */ = { | ||
186 | + isa = PBXProject; | ||
187 | + attributes = { | ||
188 | + DefaultBuildSystemTypeForWorkspace = Original; | ||
189 | + LastUpgradeCheck = 1300; | ||
190 | + ORGANIZATIONNAME = "The Flutter Authors"; | ||
191 | + TargetAttributes = { | ||
192 | + 97C146ED1CF9000F007C117D = { | ||
193 | + CreatedOnToolsVersion = 7.3.1; | ||
194 | + SystemCapabilities = { | ||
195 | + com.apple.BackgroundModes = { | ||
196 | + enabled = 1; | ||
197 | + }; | ||
198 | + }; | ||
199 | + }; | ||
200 | + }; | ||
201 | + }; | ||
202 | + buildConfigurationList = 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */; | ||
203 | + compatibilityVersion = "Xcode 3.2"; | ||
204 | + developmentRegion = en; | ||
205 | + hasScannedForEncodings = 0; | ||
206 | + knownRegions = ( | ||
207 | + en, | ||
208 | + Base, | ||
209 | + ); | ||
210 | + mainGroup = 97C146E51CF9000F007C117D; | ||
211 | + productRefGroup = 97C146EF1CF9000F007C117D /* Products */; | ||
212 | + projectDirPath = ""; | ||
213 | + projectRoot = ""; | ||
214 | + targets = ( | ||
215 | + 97C146ED1CF9000F007C117D /* Runner */, | ||
216 | + ); | ||
217 | + }; | ||
218 | +/* End PBXProject section */ | ||
219 | + | ||
220 | +/* Begin PBXResourcesBuildPhase section */ | ||
221 | + 97C146EC1CF9000F007C117D /* Resources */ = { | ||
222 | + isa = PBXResourcesBuildPhase; | ||
223 | + buildActionMask = 2147483647; | ||
224 | + files = ( | ||
225 | + 97C147011CF9000F007C117D /* LaunchScreen.storyboard in Resources */, | ||
226 | + 9FC8F0E9229FA49E00C8D58F /* gifImage.gif in Resources */, | ||
227 | + 3B3967161E833CAA004F5970 /* AppFrameworkInfo.plist in Resources */, | ||
228 | + 97C146FC1CF9000F007C117D /* Main.storyboard in Resources */, | ||
229 | + ); | ||
230 | + runOnlyForDeploymentPostprocessing = 0; | ||
231 | + }; | ||
232 | +/* End PBXResourcesBuildPhase section */ | ||
233 | + | ||
234 | +/* Begin PBXShellScriptBuildPhase section */ | ||
235 | + 3B06AD1E1E4923F5004D2608 /* Thin Binary */ = { | ||
236 | + isa = PBXShellScriptBuildPhase; | ||
237 | + alwaysOutOfDate = 1; | ||
238 | + buildActionMask = 2147483647; | ||
239 | + files = ( | ||
240 | + ); | ||
241 | + inputPaths = ( | ||
242 | + "${TARGET_BUILD_DIR}/${INFOPLIST_PATH}", | ||
243 | + ); | ||
244 | + name = "Thin Binary"; | ||
245 | + outputPaths = ( | ||
246 | + ); | ||
247 | + runOnlyForDeploymentPostprocessing = 0; | ||
248 | + shellPath = /bin/sh; | ||
249 | + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" embed_and_thin"; | ||
250 | + }; | ||
251 | + 9740EEB61CF901F6004384FC /* Run Script */ = { | ||
252 | + isa = PBXShellScriptBuildPhase; | ||
253 | + alwaysOutOfDate = 1; | ||
254 | + buildActionMask = 2147483647; | ||
255 | + files = ( | ||
256 | + ); | ||
257 | + inputPaths = ( | ||
258 | + ); | ||
259 | + name = "Run Script"; | ||
260 | + outputPaths = ( | ||
261 | + ); | ||
262 | + runOnlyForDeploymentPostprocessing = 0; | ||
263 | + shellPath = /bin/sh; | ||
264 | + shellScript = "/bin/sh \"$FLUTTER_ROOT/packages/flutter_tools/bin/xcode_backend.sh\" build"; | ||
265 | + }; | ||
266 | + AB1344B0443C71CD721E1BB7 /* [CP] Check Pods Manifest.lock */ = { | ||
267 | + isa = PBXShellScriptBuildPhase; | ||
268 | + buildActionMask = 2147483647; | ||
269 | + files = ( | ||
270 | + ); | ||
271 | + inputPaths = ( | ||
272 | + "${PODS_PODFILE_DIR_PATH}/Podfile.lock", | ||
273 | + "${PODS_ROOT}/Manifest.lock", | ||
274 | + ); | ||
275 | + name = "[CP] Check Pods Manifest.lock"; | ||
276 | + outputPaths = ( | ||
277 | + "$(DERIVED_FILE_DIR)/Pods-Runner-checkManifestLockResult.txt", | ||
278 | + ); | ||
279 | + runOnlyForDeploymentPostprocessing = 0; | ||
280 | + shellPath = /bin/sh; | ||
281 | + shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; | ||
282 | + showEnvVarsInLog = 0; | ||
283 | + }; | ||
284 | +/* End PBXShellScriptBuildPhase section */ | ||
285 | + | ||
286 | +/* Begin PBXSourcesBuildPhase section */ | ||
287 | + 97C146EA1CF9000F007C117D /* Sources */ = { | ||
288 | + isa = PBXSourcesBuildPhase; | ||
289 | + buildActionMask = 2147483647; | ||
290 | + files = ( | ||
291 | + 978B8F6F1D3862AE00F588F7 /* AppDelegate.m in Sources */, | ||
292 | + 97C146F31CF9000F007C117D /* main.m in Sources */, | ||
293 | + 5C9513011EC38BD300040975 /* GeneratedPluginRegistrant.m in Sources */, | ||
294 | + ); | ||
295 | + runOnlyForDeploymentPostprocessing = 0; | ||
296 | + }; | ||
297 | +/* End PBXSourcesBuildPhase section */ | ||
298 | + | ||
299 | +/* Begin PBXVariantGroup section */ | ||
300 | + 97C146FA1CF9000F007C117D /* Main.storyboard */ = { | ||
301 | + isa = PBXVariantGroup; | ||
302 | + children = ( | ||
303 | + 97C146FB1CF9000F007C117D /* Base */, | ||
304 | + ); | ||
305 | + name = Main.storyboard; | ||
306 | + sourceTree = "<group>"; | ||
307 | + }; | ||
308 | + 97C146FF1CF9000F007C117D /* LaunchScreen.storyboard */ = { | ||
309 | + isa = PBXVariantGroup; | ||
310 | + children = ( | ||
311 | + 97C147001CF9000F007C117D /* Base */, | ||
312 | + ); | ||
313 | + name = LaunchScreen.storyboard; | ||
314 | + sourceTree = "<group>"; | ||
315 | + }; | ||
316 | +/* End PBXVariantGroup section */ | ||
317 | + | ||
318 | +/* Begin XCBuildConfiguration section */ | ||
319 | + 97C147031CF9000F007C117D /* Debug */ = { | ||
320 | + isa = XCBuildConfiguration; | ||
321 | + buildSettings = { | ||
322 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
323 | + CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; | ||
324 | + CLANG_ANALYZER_NONNULL = YES; | ||
325 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; | ||
326 | + CLANG_CXX_LIBRARY = "libc++"; | ||
327 | + CLANG_ENABLE_MODULES = YES; | ||
328 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
329 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
330 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
331 | + CLANG_WARN_COMMA = YES; | ||
332 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
333 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
334 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
335 | + CLANG_WARN_EMPTY_BODY = YES; | ||
336 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
337 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
338 | + CLANG_WARN_INT_CONVERSION = YES; | ||
339 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
340 | + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; | ||
341 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
342 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
343 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
344 | + CLANG_WARN_STRICT_PROTOTYPES = YES; | ||
345 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
346 | + CLANG_WARN_UNREACHABLE_CODE = YES; | ||
347 | + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; | ||
348 | + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; | ||
349 | + COPY_PHASE_STRIP = NO; | ||
350 | + DEBUG_INFORMATION_FORMAT = dwarf; | ||
351 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
352 | + ENABLE_TESTABILITY = YES; | ||
353 | + GCC_C_LANGUAGE_STANDARD = gnu99; | ||
354 | + GCC_DYNAMIC_NO_PIC = NO; | ||
355 | + GCC_NO_COMMON_BLOCKS = YES; | ||
356 | + GCC_OPTIMIZATION_LEVEL = 0; | ||
357 | + GCC_PREPROCESSOR_DEFINITIONS = ( | ||
358 | + "DEBUG=1", | ||
359 | + "$(inherited)", | ||
360 | + ); | ||
361 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
362 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
363 | + GCC_WARN_UNDECLARED_SELECTOR = YES; | ||
364 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
365 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
366 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
367 | + IPHONEOS_DEPLOYMENT_TARGET = 11.0; | ||
368 | + MTL_ENABLE_DEBUG_INFO = YES; | ||
369 | + ONLY_ACTIVE_ARCH = YES; | ||
370 | + SDKROOT = iphoneos; | ||
371 | + TARGETED_DEVICE_FAMILY = "1,2"; | ||
372 | + }; | ||
373 | + name = Debug; | ||
374 | + }; | ||
375 | + 97C147041CF9000F007C117D /* Release */ = { | ||
376 | + isa = XCBuildConfiguration; | ||
377 | + buildSettings = { | ||
378 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
379 | + CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; | ||
380 | + CLANG_ANALYZER_NONNULL = YES; | ||
381 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x"; | ||
382 | + CLANG_CXX_LIBRARY = "libc++"; | ||
383 | + CLANG_ENABLE_MODULES = YES; | ||
384 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
385 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
386 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
387 | + CLANG_WARN_COMMA = YES; | ||
388 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
389 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
390 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
391 | + CLANG_WARN_EMPTY_BODY = YES; | ||
392 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
393 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
394 | + CLANG_WARN_INT_CONVERSION = YES; | ||
395 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
396 | + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; | ||
397 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
398 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
399 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
400 | + CLANG_WARN_STRICT_PROTOTYPES = YES; | ||
401 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
402 | + CLANG_WARN_UNREACHABLE_CODE = YES; | ||
403 | + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; | ||
404 | + "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; | ||
405 | + COPY_PHASE_STRIP = NO; | ||
406 | + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; | ||
407 | + ENABLE_NS_ASSERTIONS = NO; | ||
408 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
409 | + GCC_C_LANGUAGE_STANDARD = gnu99; | ||
410 | + GCC_NO_COMMON_BLOCKS = YES; | ||
411 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
412 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
413 | + GCC_WARN_UNDECLARED_SELECTOR = YES; | ||
414 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
415 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
416 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
417 | + IPHONEOS_DEPLOYMENT_TARGET = 11.0; | ||
418 | + MTL_ENABLE_DEBUG_INFO = NO; | ||
419 | + SDKROOT = iphoneos; | ||
420 | + TARGETED_DEVICE_FAMILY = "1,2"; | ||
421 | + VALIDATE_PRODUCT = YES; | ||
422 | + }; | ||
423 | + name = Release; | ||
424 | + }; | ||
425 | + 97C147061CF9000F007C117D /* Debug */ = { | ||
426 | + isa = XCBuildConfiguration; | ||
427 | + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; | ||
428 | + buildSettings = { | ||
429 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
430 | + ENABLE_BITCODE = NO; | ||
431 | + FRAMEWORK_SEARCH_PATHS = ( | ||
432 | + "$(inherited)", | ||
433 | + "$(PROJECT_DIR)/Flutter", | ||
434 | + ); | ||
435 | + INFOPLIST_FILE = Runner/Info.plist; | ||
436 | + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; | ||
437 | + LIBRARY_SEARCH_PATHS = ( | ||
438 | + "$(inherited)", | ||
439 | + "$(PROJECT_DIR)/Flutter", | ||
440 | + ); | ||
441 | + PRODUCT_BUNDLE_IDENTIFIER = dev.flutter.plugins.imagePickerExample; | ||
442 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
443 | + }; | ||
444 | + name = Debug; | ||
445 | + }; | ||
446 | + 97C147071CF9000F007C117D /* Release */ = { | ||
447 | + isa = XCBuildConfiguration; | ||
448 | + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; | ||
449 | + buildSettings = { | ||
450 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
451 | + ENABLE_BITCODE = NO; | ||
452 | + FRAMEWORK_SEARCH_PATHS = ( | ||
453 | + "$(inherited)", | ||
454 | + "$(PROJECT_DIR)/Flutter", | ||
455 | + ); | ||
456 | + INFOPLIST_FILE = Runner/Info.plist; | ||
457 | + LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks"; | ||
458 | + LIBRARY_SEARCH_PATHS = ( | ||
459 | + "$(inherited)", | ||
460 | + "$(PROJECT_DIR)/Flutter", | ||
461 | + ); | ||
462 | + PRODUCT_BUNDLE_IDENTIFIER = dev.flutter.plugins.imagePickerExample; | ||
463 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
464 | + }; | ||
465 | + name = Release; | ||
466 | + }; | ||
467 | +/* End XCBuildConfiguration section */ | ||
468 | + | ||
469 | +/* Begin XCConfigurationList section */ | ||
470 | + 97C146E91CF9000F007C117D /* Build configuration list for PBXProject "Runner" */ = { | ||
471 | + isa = XCConfigurationList; | ||
472 | + buildConfigurations = ( | ||
473 | + 97C147031CF9000F007C117D /* Debug */, | ||
474 | + 97C147041CF9000F007C117D /* Release */, | ||
475 | + ); | ||
476 | + defaultConfigurationIsVisible = 0; | ||
477 | + defaultConfigurationName = Release; | ||
478 | + }; | ||
479 | + 97C147051CF9000F007C117D /* Build configuration list for PBXNativeTarget "Runner" */ = { | ||
480 | + isa = XCConfigurationList; | ||
481 | + buildConfigurations = ( | ||
482 | + 97C147061CF9000F007C117D /* Debug */, | ||
483 | + 97C147071CF9000F007C117D /* Release */, | ||
484 | + ); | ||
485 | + defaultConfigurationIsVisible = 0; | ||
486 | + defaultConfigurationName = Release; | ||
487 | + }; | ||
488 | +/* End XCConfigurationList section */ | ||
489 | + }; | ||
490 | + rootObject = 97C146E61CF9000F007C117D /* Project object */; | ||
491 | +} |
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<Scheme | ||
3 | + LastUpgradeVersion = "1300" | ||
4 | + version = "1.3"> | ||
5 | + <BuildAction | ||
6 | + parallelizeBuildables = "YES" | ||
7 | + buildImplicitDependencies = "YES"> | ||
8 | + <BuildActionEntries> | ||
9 | + <BuildActionEntry | ||
10 | + buildForTesting = "YES" | ||
11 | + buildForRunning = "YES" | ||
12 | + buildForProfiling = "YES" | ||
13 | + buildForArchiving = "YES" | ||
14 | + buildForAnalyzing = "YES"> | ||
15 | + <BuildableReference | ||
16 | + BuildableIdentifier = "primary" | ||
17 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
18 | + BuildableName = "Runner.app" | ||
19 | + BlueprintName = "Runner" | ||
20 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
21 | + </BuildableReference> | ||
22 | + </BuildActionEntry> | ||
23 | + </BuildActionEntries> | ||
24 | + </BuildAction> | ||
25 | + <TestAction | ||
26 | + buildConfiguration = "Debug" | ||
27 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
28 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
29 | + shouldUseLaunchSchemeArgsEnv = "YES"> | ||
30 | + <MacroExpansion> | ||
31 | + <BuildableReference | ||
32 | + BuildableIdentifier = "primary" | ||
33 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
34 | + BuildableName = "Runner.app" | ||
35 | + BlueprintName = "Runner" | ||
36 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
37 | + </BuildableReference> | ||
38 | + </MacroExpansion> | ||
39 | + <Testables> | ||
40 | + <TestableReference | ||
41 | + skipped = "NO"> | ||
42 | + <BuildableReference | ||
43 | + BuildableIdentifier = "primary" | ||
44 | + BlueprintIdentifier = "6801C8352555D726009DAF8D" | ||
45 | + BuildableName = "RunnerUITests.xctest" | ||
46 | + BlueprintName = "RunnerUITests" | ||
47 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
48 | + </BuildableReference> | ||
49 | + </TestableReference> | ||
50 | + <TestableReference | ||
51 | + skipped = "NO"> | ||
52 | + <BuildableReference | ||
53 | + BuildableIdentifier = "primary" | ||
54 | + BlueprintIdentifier = "BE7AEE6B26403C46006181AA" | ||
55 | + BuildableName = "RunnerUITestiOS14.xctest" | ||
56 | + BlueprintName = "RunnerUITestiOS14" | ||
57 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
58 | + </BuildableReference> | ||
59 | + </TestableReference> | ||
60 | + <TestableReference | ||
61 | + skipped = "NO"> | ||
62 | + <BuildableReference | ||
63 | + BuildableIdentifier = "primary" | ||
64 | + BlueprintIdentifier = "334733F12668136400DCC49E" | ||
65 | + BuildableName = "RunnerTests.xctest" | ||
66 | + BlueprintName = "RunnerTests" | ||
67 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
68 | + </BuildableReference> | ||
69 | + </TestableReference> | ||
70 | + </Testables> | ||
71 | + </TestAction> | ||
72 | + <LaunchAction | ||
73 | + buildConfiguration = "Debug" | ||
74 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
75 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
76 | + launchStyle = "0" | ||
77 | + useCustomWorkingDirectory = "NO" | ||
78 | + ignoresPersistentStateOnLaunch = "NO" | ||
79 | + debugDocumentVersioning = "YES" | ||
80 | + debugServiceExtension = "internal" | ||
81 | + allowLocationSimulation = "YES"> | ||
82 | + <BuildableProductRunnable | ||
83 | + runnableDebuggingMode = "0"> | ||
84 | + <BuildableReference | ||
85 | + BuildableIdentifier = "primary" | ||
86 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
87 | + BuildableName = "Runner.app" | ||
88 | + BlueprintName = "Runner" | ||
89 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
90 | + </BuildableReference> | ||
91 | + </BuildableProductRunnable> | ||
92 | + </LaunchAction> | ||
93 | + <ProfileAction | ||
94 | + buildConfiguration = "Release" | ||
95 | + shouldUseLaunchSchemeArgsEnv = "YES" | ||
96 | + savedToolIdentifier = "" | ||
97 | + useCustomWorkingDirectory = "NO" | ||
98 | + debugDocumentVersioning = "YES"> | ||
99 | + <BuildableProductRunnable | ||
100 | + runnableDebuggingMode = "0"> | ||
101 | + <BuildableReference | ||
102 | + BuildableIdentifier = "primary" | ||
103 | + BlueprintIdentifier = "97C146ED1CF9000F007C117D" | ||
104 | + BuildableName = "Runner.app" | ||
105 | + BlueprintName = "Runner" | ||
106 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
107 | + </BuildableReference> | ||
108 | + </BuildableProductRunnable> | ||
109 | + </ProfileAction> | ||
110 | + <AnalyzeAction | ||
111 | + buildConfiguration = "Debug"> | ||
112 | + </AnalyzeAction> | ||
113 | + <ArchiveAction | ||
114 | + buildConfiguration = "Release" | ||
115 | + revealArchiveInOrganizer = "YES"> | ||
116 | + </ArchiveAction> | ||
117 | +</Scheme> |
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<Scheme | ||
3 | + LastUpgradeVersion = "1240" | ||
4 | + version = "1.3"> | ||
5 | + <BuildAction | ||
6 | + parallelizeBuildables = "YES" | ||
7 | + buildImplicitDependencies = "YES"> | ||
8 | + </BuildAction> | ||
9 | + <TestAction | ||
10 | + buildConfiguration = "Debug" | ||
11 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
12 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
13 | + shouldUseLaunchSchemeArgsEnv = "YES"> | ||
14 | + <Testables> | ||
15 | + <TestableReference | ||
16 | + skipped = "NO"> | ||
17 | + <BuildableReference | ||
18 | + BuildableIdentifier = "primary" | ||
19 | + BlueprintIdentifier = "6801C8352555D726009DAF8D" | ||
20 | + BuildableName = "RunnerUITests.xctest" | ||
21 | + BlueprintName = "RunnerUITests" | ||
22 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
23 | + </BuildableReference> | ||
24 | + </TestableReference> | ||
25 | + </Testables> | ||
26 | + </TestAction> | ||
27 | + <LaunchAction | ||
28 | + buildConfiguration = "Debug" | ||
29 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
30 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
31 | + launchStyle = "0" | ||
32 | + useCustomWorkingDirectory = "NO" | ||
33 | + ignoresPersistentStateOnLaunch = "NO" | ||
34 | + debugDocumentVersioning = "YES" | ||
35 | + debugServiceExtension = "internal" | ||
36 | + allowLocationSimulation = "YES"> | ||
37 | + </LaunchAction> | ||
38 | + <ProfileAction | ||
39 | + buildConfiguration = "Release" | ||
40 | + shouldUseLaunchSchemeArgsEnv = "YES" | ||
41 | + savedToolIdentifier = "" | ||
42 | + useCustomWorkingDirectory = "NO" | ||
43 | + debugDocumentVersioning = "YES"> | ||
44 | + </ProfileAction> | ||
45 | + <AnalyzeAction | ||
46 | + buildConfiguration = "Debug"> | ||
47 | + </AnalyzeAction> | ||
48 | + <ArchiveAction | ||
49 | + buildConfiguration = "Release" | ||
50 | + revealArchiveInOrganizer = "YES"> | ||
51 | + </ArchiveAction> | ||
52 | +</Scheme> |
image_picker/example/ios/Runner/.gitignore
0 → 100644
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +#include "AppDelegate.h" | ||
6 | +#include "GeneratedPluginRegistrant.h" | ||
7 | + | ||
8 | +@implementation AppDelegate | ||
9 | + | ||
10 | +- (BOOL)application:(UIApplication *)application | ||
11 | + didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { | ||
12 | + [GeneratedPluginRegistrant registerWithRegistry:self]; | ||
13 | + return [super application:application didFinishLaunchingWithOptions:launchOptions]; | ||
14 | +} | ||
15 | + | ||
16 | +@end |
1 | +{ | ||
2 | + "images" : [ | ||
3 | + { | ||
4 | + "size" : "20x20", | ||
5 | + "idiom" : "iphone", | ||
6 | + "filename" : "Icon-App-20x20@2x.png", | ||
7 | + "scale" : "2x" | ||
8 | + }, | ||
9 | + { | ||
10 | + "size" : "20x20", | ||
11 | + "idiom" : "iphone", | ||
12 | + "filename" : "Icon-App-20x20@3x.png", | ||
13 | + "scale" : "3x" | ||
14 | + }, | ||
15 | + { | ||
16 | + "size" : "29x29", | ||
17 | + "idiom" : "iphone", | ||
18 | + "filename" : "Icon-App-29x29@1x.png", | ||
19 | + "scale" : "1x" | ||
20 | + }, | ||
21 | + { | ||
22 | + "size" : "29x29", | ||
23 | + "idiom" : "iphone", | ||
24 | + "filename" : "Icon-App-29x29@2x.png", | ||
25 | + "scale" : "2x" | ||
26 | + }, | ||
27 | + { | ||
28 | + "size" : "29x29", | ||
29 | + "idiom" : "iphone", | ||
30 | + "filename" : "Icon-App-29x29@3x.png", | ||
31 | + "scale" : "3x" | ||
32 | + }, | ||
33 | + { | ||
34 | + "size" : "40x40", | ||
35 | + "idiom" : "iphone", | ||
36 | + "filename" : "Icon-App-40x40@2x.png", | ||
37 | + "scale" : "2x" | ||
38 | + }, | ||
39 | + { | ||
40 | + "size" : "40x40", | ||
41 | + "idiom" : "iphone", | ||
42 | + "filename" : "Icon-App-40x40@3x.png", | ||
43 | + "scale" : "3x" | ||
44 | + }, | ||
45 | + { | ||
46 | + "size" : "60x60", | ||
47 | + "idiom" : "iphone", | ||
48 | + "filename" : "Icon-App-60x60@2x.png", | ||
49 | + "scale" : "2x" | ||
50 | + }, | ||
51 | + { | ||
52 | + "size" : "60x60", | ||
53 | + "idiom" : "iphone", | ||
54 | + "filename" : "Icon-App-60x60@3x.png", | ||
55 | + "scale" : "3x" | ||
56 | + }, | ||
57 | + { | ||
58 | + "size" : "20x20", | ||
59 | + "idiom" : "ipad", | ||
60 | + "filename" : "Icon-App-20x20@1x.png", | ||
61 | + "scale" : "1x" | ||
62 | + }, | ||
63 | + { | ||
64 | + "size" : "20x20", | ||
65 | + "idiom" : "ipad", | ||
66 | + "filename" : "Icon-App-20x20@2x.png", | ||
67 | + "scale" : "2x" | ||
68 | + }, | ||
69 | + { | ||
70 | + "size" : "29x29", | ||
71 | + "idiom" : "ipad", | ||
72 | + "filename" : "Icon-App-29x29@1x.png", | ||
73 | + "scale" : "1x" | ||
74 | + }, | ||
75 | + { | ||
76 | + "size" : "29x29", | ||
77 | + "idiom" : "ipad", | ||
78 | + "filename" : "Icon-App-29x29@2x.png", | ||
79 | + "scale" : "2x" | ||
80 | + }, | ||
81 | + { | ||
82 | + "size" : "40x40", | ||
83 | + "idiom" : "ipad", | ||
84 | + "filename" : "Icon-App-40x40@1x.png", | ||
85 | + "scale" : "1x" | ||
86 | + }, | ||
87 | + { | ||
88 | + "size" : "40x40", | ||
89 | + "idiom" : "ipad", | ||
90 | + "filename" : "Icon-App-40x40@2x.png", | ||
91 | + "scale" : "2x" | ||
92 | + }, | ||
93 | + { | ||
94 | + "size" : "76x76", | ||
95 | + "idiom" : "ipad", | ||
96 | + "filename" : "Icon-App-76x76@1x.png", | ||
97 | + "scale" : "1x" | ||
98 | + }, | ||
99 | + { | ||
100 | + "size" : "76x76", | ||
101 | + "idiom" : "ipad", | ||
102 | + "filename" : "Icon-App-76x76@2x.png", | ||
103 | + "scale" : "2x" | ||
104 | + }, | ||
105 | + { | ||
106 | + "size" : "83.5x83.5", | ||
107 | + "idiom" : "ipad", | ||
108 | + "filename" : "Icon-App-83.5x83.5@2x.png", | ||
109 | + "scale" : "2x" | ||
110 | + }, | ||
111 | + { | ||
112 | + "idiom" : "ios-marketing", | ||
113 | + "size" : "1024x1024", | ||
114 | + "scale" : "1x" | ||
115 | + } | ||
116 | + ], | ||
117 | + "info" : { | ||
118 | + "version" : 1, | ||
119 | + "author" : "xcode" | ||
120 | + } | ||
121 | +} |

564 Bytes

1.25 KB

1.55 KB

1 KB

1.68 KB

1.88 KB

1.25 KB

1.85 KB

2.6 KB

2.6 KB

3.74 KB

1.84 KB

3.22 KB
image_picker/example/ios/Runner/Assets.xcassets/AppIcon.appiconset/Icon-App-83.5x83.5@2x.png
0 → 100644

3.53 KB
1 | +<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
2 | +<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" initialViewController="01J-lp-oVM"> | ||
3 | + <dependencies> | ||
4 | + <deployment identifier="iOS"/> | ||
5 | + <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/> | ||
6 | + </dependencies> | ||
7 | + <scenes> | ||
8 | + <!--View Controller--> | ||
9 | + <scene sceneID="EHf-IW-A2E"> | ||
10 | + <objects> | ||
11 | + <viewController id="01J-lp-oVM" sceneMemberID="viewController"> | ||
12 | + <layoutGuides> | ||
13 | + <viewControllerLayoutGuide type="top" id="Llm-lL-Icb"/> | ||
14 | + <viewControllerLayoutGuide type="bottom" id="xb3-aO-Qok"/> | ||
15 | + </layoutGuides> | ||
16 | + <view key="view" contentMode="scaleToFill" id="Ze5-6b-2t3"> | ||
17 | + <rect key="frame" x="0.0" y="0.0" width="600" height="600"/> | ||
18 | + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> | ||
19 | + <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/> | ||
20 | + </view> | ||
21 | + </viewController> | ||
22 | + <placeholder placeholderIdentifier="IBFirstResponder" id="iYj-Kq-Ea1" userLabel="First Responder" sceneMemberID="firstResponder"/> | ||
23 | + </objects> | ||
24 | + <point key="canvasLocation" x="53" y="375"/> | ||
25 | + </scene> | ||
26 | + </scenes> | ||
27 | +</document> |
1 | +<?xml version="1.0" encoding="UTF-8" standalone="no"?> | ||
2 | +<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r"> | ||
3 | + <dependencies> | ||
4 | + <deployment identifier="iOS"/> | ||
5 | + <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/> | ||
6 | + </dependencies> | ||
7 | + <scenes> | ||
8 | + <!--Flutter View Controller--> | ||
9 | + <scene sceneID="tne-QT-ifu"> | ||
10 | + <objects> | ||
11 | + <viewController id="BYZ-38-t0r" customClass="FlutterViewController" sceneMemberID="viewController"> | ||
12 | + <layoutGuides> | ||
13 | + <viewControllerLayoutGuide type="top" id="y3c-jy-aDJ"/> | ||
14 | + <viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/> | ||
15 | + </layoutGuides> | ||
16 | + <view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC"> | ||
17 | + <rect key="frame" x="0.0" y="0.0" width="600" height="600"/> | ||
18 | + <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/> | ||
19 | + <color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/> | ||
20 | + </view> | ||
21 | + </viewController> | ||
22 | + <placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/> | ||
23 | + </objects> | ||
24 | + </scene> | ||
25 | + </scenes> | ||
26 | +</document> |
image_picker/example/ios/Runner/Info.plist
0 → 100644
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
3 | +<plist version="1.0"> | ||
4 | +<dict> | ||
5 | + <key>CFBundleDevelopmentRegion</key> | ||
6 | + <string>en</string> | ||
7 | + <key>CFBundleExecutable</key> | ||
8 | + <string>$(EXECUTABLE_NAME)</string> | ||
9 | + <key>CFBundleIdentifier</key> | ||
10 | + <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> | ||
11 | + <key>CFBundleInfoDictionaryVersion</key> | ||
12 | + <string>6.0</string> | ||
13 | + <key>CFBundleName</key> | ||
14 | + <string>image_picker_example</string> | ||
15 | + <key>CFBundlePackageType</key> | ||
16 | + <string>APPL</string> | ||
17 | + <key>CFBundleShortVersionString</key> | ||
18 | + <string>1.0</string> | ||
19 | + <key>CFBundleSignature</key> | ||
20 | + <string>????</string> | ||
21 | + <key>CFBundleVersion</key> | ||
22 | + <string>1</string> | ||
23 | + <key>LSRequiresIPhoneOS</key> | ||
24 | + <true/> | ||
25 | + <key>NSCameraUsageDescription</key> | ||
26 | + <string>Used to demonstrate image picker plugin</string> | ||
27 | + <key>NSMicrophoneUsageDescription</key> | ||
28 | + <string>Used to capture audio for image picker plugin</string> | ||
29 | + <key>NSPhotoLibraryUsageDescription</key> | ||
30 | + <string>Used to demonstrate image picker plugin</string> | ||
31 | + <key>UIBackgroundModes</key> | ||
32 | + <array> | ||
33 | + <string>remote-notification</string> | ||
34 | + </array> | ||
35 | + <key>UILaunchStoryboardName</key> | ||
36 | + <string>LaunchScreen</string> | ||
37 | + <key>UIMainStoryboardFile</key> | ||
38 | + <string>Main</string> | ||
39 | + <key>UIRequiredDeviceCapabilities</key> | ||
40 | + <array> | ||
41 | + <string>arm64</string> | ||
42 | + </array> | ||
43 | + <key>UISupportedInterfaceOrientations</key> | ||
44 | + <array> | ||
45 | + <string>UIInterfaceOrientationPortrait</string> | ||
46 | + <string>UIInterfaceOrientationLandscapeLeft</string> | ||
47 | + <string>UIInterfaceOrientationLandscapeRight</string> | ||
48 | + </array> | ||
49 | + <key>UISupportedInterfaceOrientations~ipad</key> | ||
50 | + <array> | ||
51 | + <string>UIInterfaceOrientationPortrait</string> | ||
52 | + <string>UIInterfaceOrientationPortraitUpsideDown</string> | ||
53 | + <string>UIInterfaceOrientationLandscapeLeft</string> | ||
54 | + <string>UIInterfaceOrientationLandscapeRight</string> | ||
55 | + </array> | ||
56 | + <key>CADisableMinimumFrameDurationOnPhone</key> | ||
57 | + <true/> | ||
58 | + <key>UIApplicationSupportsIndirectInputEvents</key> | ||
59 | + <true/> | ||
60 | +</dict> | ||
61 | +</plist> |
image_picker/example/ios/Runner/main.m
0 → 100644
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +#import <Flutter/Flutter.h> | ||
6 | +#import <UIKit/UIKit.h> | ||
7 | +#import "AppDelegate.h" | ||
8 | + | ||
9 | +int main(int argc, char *argv[]) { | ||
10 | + @autoreleasepool { | ||
11 | + return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); | ||
12 | + } | ||
13 | +} |

843 Bytes

3.21 KB

593 Bytes
No preview for this file type
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
3 | +<plist version="1.0"> | ||
4 | +<dict> | ||
5 | + <key>CFBundleDevelopmentRegion</key> | ||
6 | + <string>$(DEVELOPMENT_LANGUAGE)</string> | ||
7 | + <key>CFBundleExecutable</key> | ||
8 | + <string>$(EXECUTABLE_NAME)</string> | ||
9 | + <key>CFBundleIdentifier</key> | ||
10 | + <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> | ||
11 | + <key>CFBundleInfoDictionaryVersion</key> | ||
12 | + <string>6.0</string> | ||
13 | + <key>CFBundleName</key> | ||
14 | + <string>$(PRODUCT_NAME)</string> | ||
15 | + <key>CFBundlePackageType</key> | ||
16 | + <string>BNDL</string> | ||
17 | + <key>CFBundleShortVersionString</key> | ||
18 | + <string>1.0</string> | ||
19 | + <key>CFBundleVersion</key> | ||
20 | + <string>1</string> | ||
21 | +</dict> | ||
22 | +</plist> |
image_picker/example/lib/main.dart
0 → 100644
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +// ignore_for_file: public_member_api_docs | ||
6 | + | ||
7 | +import 'dart:async'; | ||
8 | +import 'dart:io'; | ||
9 | + | ||
10 | +import 'package:flutter/foundation.dart'; | ||
11 | +import 'package:flutter/material.dart'; | ||
12 | +import 'package:image_picker/image_picker.dart'; | ||
13 | +import 'package:mime/mime.dart'; | ||
14 | +import 'package:video_player/video_player.dart'; | ||
15 | + | ||
16 | +void main() { | ||
17 | + runApp(const MyApp()); | ||
18 | +} | ||
19 | + | ||
20 | +class MyApp extends StatelessWidget { | ||
21 | + const MyApp({super.key}); | ||
22 | + | ||
23 | + @override | ||
24 | + Widget build(BuildContext context) { | ||
25 | + return const MaterialApp( | ||
26 | + title: 'Image Picker Demo', | ||
27 | + home: MyHomePage(title: 'Image Picker Example'), | ||
28 | + ); | ||
29 | + } | ||
30 | +} | ||
31 | + | ||
32 | +class MyHomePage extends StatefulWidget { | ||
33 | + const MyHomePage({super.key, this.title}); | ||
34 | + | ||
35 | + final String? title; | ||
36 | + | ||
37 | + @override | ||
38 | + State<MyHomePage> createState() => _MyHomePageState(); | ||
39 | +} | ||
40 | + | ||
41 | +class _MyHomePageState extends State<MyHomePage> { | ||
42 | + List<XFile>? _mediaFileList; | ||
43 | + | ||
44 | + void _setImageFileListFromFile(XFile? value) { | ||
45 | + _mediaFileList = value == null ? null : <XFile>[value]; | ||
46 | + } | ||
47 | + | ||
48 | + dynamic _pickImageError; | ||
49 | + bool isVideo = false; | ||
50 | + | ||
51 | + VideoPlayerController? _controller; | ||
52 | + VideoPlayerController? _toBeDisposed; | ||
53 | + String? _retrieveDataError; | ||
54 | + | ||
55 | + final ImagePicker _picker = ImagePicker(); | ||
56 | + final TextEditingController maxWidthController = TextEditingController(); | ||
57 | + final TextEditingController maxHeightController = TextEditingController(); | ||
58 | + final TextEditingController qualityController = TextEditingController(); | ||
59 | + | ||
60 | + Future<void> _playVideo(XFile? file) async { | ||
61 | + if (file != null && mounted) { | ||
62 | + await _disposeVideoController(); | ||
63 | + late VideoPlayerController controller; | ||
64 | + if (kIsWeb) { | ||
65 | + // TODO(gabrielokura): remove the ignore once the following line can migrate to | ||
66 | + // use VideoPlayerController.networkUrl after the issue is resolved. | ||
67 | + // https://github.com/flutter/flutter/issues/121927 | ||
68 | + // ignore: deprecated_member_use | ||
69 | + controller = VideoPlayerController.network(file.path); | ||
70 | + } else { | ||
71 | + controller = VideoPlayerController.file(File(file.path)); | ||
72 | + } | ||
73 | + _controller = controller; | ||
74 | + // In web, most browsers won't honor a programmatic call to .play | ||
75 | + // if the video has a sound track (and is not muted). | ||
76 | + // Mute the video so it auto-plays in web! | ||
77 | + // This is not needed if the call to .play is the result of user | ||
78 | + // interaction (clicking on a "play" button, for example). | ||
79 | + const double volume = kIsWeb ? 0.0 : 1.0; | ||
80 | + await controller.setVolume(volume); | ||
81 | + await controller.initialize(); | ||
82 | + await controller.setLooping(true); | ||
83 | + await controller.play(); | ||
84 | + setState(() {}); | ||
85 | + } | ||
86 | + } | ||
87 | + | ||
88 | + Future<void> _onImageButtonPressed( | ||
89 | + ImageSource source, { | ||
90 | + required BuildContext context, | ||
91 | + bool isMultiImage = false, | ||
92 | + bool isMedia = false, | ||
93 | + }) async { | ||
94 | + if (_controller != null) { | ||
95 | + await _controller!.setVolume(0.0); | ||
96 | + } | ||
97 | + if (context.mounted) { | ||
98 | + if (isVideo) { | ||
99 | + final XFile? file = await _picker.pickVideo( | ||
100 | + source: source, maxDuration: const Duration(seconds: 10)); | ||
101 | + await _playVideo(file); | ||
102 | + } else if (isMultiImage) { | ||
103 | + await _displayPickImageDialog(context, | ||
104 | + (double? maxWidth, double? maxHeight, int? quality) async { | ||
105 | + try { | ||
106 | + final List<XFile> pickedFileList = isMedia | ||
107 | + ? await _picker.pickMultipleMedia( | ||
108 | + maxWidth: maxWidth, | ||
109 | + maxHeight: maxHeight, | ||
110 | + imageQuality: quality, | ||
111 | + ) | ||
112 | + : await _picker.pickMultiImage( | ||
113 | + maxWidth: maxWidth, | ||
114 | + maxHeight: maxHeight, | ||
115 | + imageQuality: quality, | ||
116 | + ); | ||
117 | + setState(() { | ||
118 | + _mediaFileList = pickedFileList; | ||
119 | + }); | ||
120 | + } catch (e) { | ||
121 | + setState(() { | ||
122 | + _pickImageError = e; | ||
123 | + }); | ||
124 | + } | ||
125 | + }); | ||
126 | + } else if (isMedia) { | ||
127 | + await _displayPickImageDialog(context, | ||
128 | + (double? maxWidth, double? maxHeight, int? quality) async { | ||
129 | + try { | ||
130 | + final List<XFile> pickedFileList = <XFile>[]; | ||
131 | + final XFile? media = await _picker.pickMedia( | ||
132 | + maxWidth: maxWidth, | ||
133 | + maxHeight: maxHeight, | ||
134 | + imageQuality: quality, | ||
135 | + ); | ||
136 | + if (media != null) { | ||
137 | + pickedFileList.add(media); | ||
138 | + setState(() { | ||
139 | + _mediaFileList = pickedFileList; | ||
140 | + }); | ||
141 | + } | ||
142 | + } catch (e) { | ||
143 | + setState(() { | ||
144 | + _pickImageError = e; | ||
145 | + }); | ||
146 | + } | ||
147 | + }); | ||
148 | + } else { | ||
149 | + await _displayPickImageDialog(context, | ||
150 | + (double? maxWidth, double? maxHeight, int? quality) async { | ||
151 | + try { | ||
152 | + final XFile? pickedFile = await _picker.pickImage( | ||
153 | + source: source, | ||
154 | + maxWidth: maxWidth, | ||
155 | + maxHeight: maxHeight, | ||
156 | + imageQuality: quality, | ||
157 | + ); | ||
158 | + setState(() { | ||
159 | + _setImageFileListFromFile(pickedFile); | ||
160 | + }); | ||
161 | + } catch (e) { | ||
162 | + setState(() { | ||
163 | + _pickImageError = e; | ||
164 | + }); | ||
165 | + } | ||
166 | + }); | ||
167 | + } | ||
168 | + } | ||
169 | + } | ||
170 | + | ||
171 | + @override | ||
172 | + void deactivate() { | ||
173 | + if (_controller != null) { | ||
174 | + _controller!.setVolume(0.0); | ||
175 | + _controller!.pause(); | ||
176 | + } | ||
177 | + super.deactivate(); | ||
178 | + } | ||
179 | + | ||
180 | + @override | ||
181 | + void dispose() { | ||
182 | + _disposeVideoController(); | ||
183 | + maxWidthController.dispose(); | ||
184 | + maxHeightController.dispose(); | ||
185 | + qualityController.dispose(); | ||
186 | + super.dispose(); | ||
187 | + } | ||
188 | + | ||
189 | + Future<void> _disposeVideoController() async { | ||
190 | + if (_toBeDisposed != null) { | ||
191 | + await _toBeDisposed!.dispose(); | ||
192 | + } | ||
193 | + _toBeDisposed = _controller; | ||
194 | + _controller = null; | ||
195 | + } | ||
196 | + | ||
197 | + Widget _previewVideo() { | ||
198 | + final Text? retrieveError = _getRetrieveErrorWidget(); | ||
199 | + if (retrieveError != null) { | ||
200 | + return retrieveError; | ||
201 | + } | ||
202 | + if (_controller == null) { | ||
203 | + return const Text( | ||
204 | + 'You have not yet picked a video', | ||
205 | + textAlign: TextAlign.center, | ||
206 | + ); | ||
207 | + } | ||
208 | + return Padding( | ||
209 | + padding: const EdgeInsets.all(10.0), | ||
210 | + child: AspectRatioVideo(_controller), | ||
211 | + ); | ||
212 | + } | ||
213 | + | ||
214 | + Widget _previewImages() { | ||
215 | + final Text? retrieveError = _getRetrieveErrorWidget(); | ||
216 | + if (retrieveError != null) { | ||
217 | + return retrieveError; | ||
218 | + } | ||
219 | + if (_mediaFileList != null) { | ||
220 | + return Semantics( | ||
221 | + label: 'image_picker_example_picked_images', | ||
222 | + child: ListView.builder( | ||
223 | + key: UniqueKey(), | ||
224 | + itemBuilder: (BuildContext context, int index) { | ||
225 | + final String? mime = lookupMimeType(_mediaFileList![index].path); | ||
226 | + | ||
227 | + // Why network for web? | ||
228 | + // See https://pub.dev/packages/image_picker_for_web#limitations-on-the-web-platform | ||
229 | + return Semantics( | ||
230 | + label: 'image_picker_example_picked_image', | ||
231 | + child: kIsWeb | ||
232 | + ? Image.network(_mediaFileList![index].path) | ||
233 | + : (mime == null || mime.startsWith('image/') | ||
234 | + ? Image.file( | ||
235 | + File(_mediaFileList![index].path), | ||
236 | + errorBuilder: (BuildContext context, Object error, | ||
237 | + StackTrace? stackTrace) { | ||
238 | + return const Center( | ||
239 | + child: | ||
240 | + Text('This image type is not supported')); | ||
241 | + }, | ||
242 | + ) | ||
243 | + : _buildInlineVideoPlayer(index)), | ||
244 | + ); | ||
245 | + }, | ||
246 | + itemCount: _mediaFileList!.length, | ||
247 | + ), | ||
248 | + ); | ||
249 | + } else if (_pickImageError != null) { | ||
250 | + return Text( | ||
251 | + 'Pick image error: $_pickImageError', | ||
252 | + textAlign: TextAlign.center, | ||
253 | + ); | ||
254 | + } else { | ||
255 | + return const Text( | ||
256 | + 'You have not yet picked an image.', | ||
257 | + textAlign: TextAlign.center, | ||
258 | + ); | ||
259 | + } | ||
260 | + } | ||
261 | + | ||
262 | + Widget _buildInlineVideoPlayer(int index) { | ||
263 | + final VideoPlayerController controller = | ||
264 | + VideoPlayerController.file(File(_mediaFileList![index].path)); | ||
265 | + const double volume = kIsWeb ? 0.0 : 1.0; | ||
266 | + controller.setVolume(volume); | ||
267 | + controller.initialize(); | ||
268 | + controller.setLooping(true); | ||
269 | + controller.play(); | ||
270 | + return Center(child: AspectRatioVideo(controller)); | ||
271 | + } | ||
272 | + | ||
273 | + Widget _handlePreview() { | ||
274 | + if (isVideo) { | ||
275 | + return _previewVideo(); | ||
276 | + } else { | ||
277 | + return _previewImages(); | ||
278 | + } | ||
279 | + } | ||
280 | + | ||
281 | + Future<void> retrieveLostData() async { | ||
282 | + final LostDataResponse response = await _picker.retrieveLostData(); | ||
283 | + if (response.isEmpty) { | ||
284 | + return; | ||
285 | + } | ||
286 | + if (response.file != null) { | ||
287 | + if (response.type == RetrieveType.video) { | ||
288 | + isVideo = true; | ||
289 | + await _playVideo(response.file); | ||
290 | + } else { | ||
291 | + isVideo = false; | ||
292 | + setState(() { | ||
293 | + if (response.files == null) { | ||
294 | + _setImageFileListFromFile(response.file); | ||
295 | + } else { | ||
296 | + _mediaFileList = response.files; | ||
297 | + } | ||
298 | + }); | ||
299 | + } | ||
300 | + } else { | ||
301 | + _retrieveDataError = response.exception!.code; | ||
302 | + } | ||
303 | + } | ||
304 | + | ||
305 | + @override | ||
306 | + Widget build(BuildContext context) { | ||
307 | + return Scaffold( | ||
308 | + appBar: AppBar( | ||
309 | + title: Text(widget.title!), | ||
310 | + ), | ||
311 | + body: Center( | ||
312 | + child: !kIsWeb && defaultTargetPlatform == TargetPlatform.android | ||
313 | + ? FutureBuilder<void>( | ||
314 | + future: retrieveLostData(), | ||
315 | + builder: (BuildContext context, AsyncSnapshot<void> snapshot) { | ||
316 | + switch (snapshot.connectionState) { | ||
317 | + case ConnectionState.none: | ||
318 | + case ConnectionState.waiting: | ||
319 | + return const Text( | ||
320 | + 'You have not yet picked an image.', | ||
321 | + textAlign: TextAlign.center, | ||
322 | + ); | ||
323 | + case ConnectionState.done: | ||
324 | + return _handlePreview(); | ||
325 | + case ConnectionState.active: | ||
326 | + if (snapshot.hasError) { | ||
327 | + return Text( | ||
328 | + 'Pick image/video error: ${snapshot.error}}', | ||
329 | + textAlign: TextAlign.center, | ||
330 | + ); | ||
331 | + } else { | ||
332 | + return const Text( | ||
333 | + 'You have not yet picked an image.', | ||
334 | + textAlign: TextAlign.center, | ||
335 | + ); | ||
336 | + } | ||
337 | + } | ||
338 | + }, | ||
339 | + ) | ||
340 | + : _handlePreview(), | ||
341 | + ), | ||
342 | + floatingActionButton: Column( | ||
343 | + mainAxisAlignment: MainAxisAlignment.end, | ||
344 | + children: <Widget>[ | ||
345 | + Semantics( | ||
346 | + label: 'image_picker_example_from_gallery', | ||
347 | + child: FloatingActionButton( | ||
348 | + onPressed: () { | ||
349 | + isVideo = false; | ||
350 | + _onImageButtonPressed(ImageSource.gallery, context: context); | ||
351 | + }, | ||
352 | + heroTag: 'image0', | ||
353 | + tooltip: 'Pick Image from gallery', | ||
354 | + child: const Icon(Icons.photo), | ||
355 | + ), | ||
356 | + ), | ||
357 | + Padding( | ||
358 | + padding: const EdgeInsets.only(top: 16.0), | ||
359 | + child: FloatingActionButton( | ||
360 | + onPressed: () { | ||
361 | + isVideo = false; | ||
362 | + _onImageButtonPressed( | ||
363 | + ImageSource.gallery, | ||
364 | + context: context, | ||
365 | + isMultiImage: true, | ||
366 | + isMedia: true, | ||
367 | + ); | ||
368 | + }, | ||
369 | + heroTag: 'multipleMedia', | ||
370 | + tooltip: 'Pick Multiple Media from gallery', | ||
371 | + child: const Icon(Icons.photo_library), | ||
372 | + ), | ||
373 | + ), | ||
374 | + Padding( | ||
375 | + padding: const EdgeInsets.only(top: 16.0), | ||
376 | + child: FloatingActionButton( | ||
377 | + onPressed: () { | ||
378 | + isVideo = false; | ||
379 | + _onImageButtonPressed( | ||
380 | + ImageSource.gallery, | ||
381 | + context: context, | ||
382 | + isMedia: true, | ||
383 | + ); | ||
384 | + }, | ||
385 | + heroTag: 'media', | ||
386 | + tooltip: 'Pick Single Media from gallery', | ||
387 | + child: const Icon(Icons.photo_library), | ||
388 | + ), | ||
389 | + ), | ||
390 | + Padding( | ||
391 | + padding: const EdgeInsets.only(top: 16.0), | ||
392 | + child: FloatingActionButton( | ||
393 | + onPressed: () { | ||
394 | + isVideo = false; | ||
395 | + _onImageButtonPressed( | ||
396 | + ImageSource.gallery, | ||
397 | + context: context, | ||
398 | + isMultiImage: true, | ||
399 | + ); | ||
400 | + }, | ||
401 | + heroTag: 'image1', | ||
402 | + tooltip: 'Pick Multiple Image from gallery', | ||
403 | + child: const Icon(Icons.photo_library), | ||
404 | + ), | ||
405 | + ), | ||
406 | + if (_picker.supportsImageSource(ImageSource.camera)) | ||
407 | + Padding( | ||
408 | + padding: const EdgeInsets.only(top: 16.0), | ||
409 | + child: FloatingActionButton( | ||
410 | + onPressed: () { | ||
411 | + isVideo = false; | ||
412 | + _onImageButtonPressed(ImageSource.camera, context: context); | ||
413 | + }, | ||
414 | + heroTag: 'image2', | ||
415 | + tooltip: 'Take a Photo', | ||
416 | + child: const Icon(Icons.camera_alt), | ||
417 | + ), | ||
418 | + ), | ||
419 | + Padding( | ||
420 | + padding: const EdgeInsets.only(top: 16.0), | ||
421 | + child: FloatingActionButton( | ||
422 | + backgroundColor: Colors.red, | ||
423 | + onPressed: () { | ||
424 | + isVideo = true; | ||
425 | + _onImageButtonPressed(ImageSource.gallery, context: context); | ||
426 | + }, | ||
427 | + heroTag: 'video0', | ||
428 | + tooltip: 'Pick Video from gallery', | ||
429 | + child: const Icon(Icons.video_library), | ||
430 | + ), | ||
431 | + ), | ||
432 | + if (_picker.supportsImageSource(ImageSource.camera)) | ||
433 | + Padding( | ||
434 | + padding: const EdgeInsets.only(top: 16.0), | ||
435 | + child: FloatingActionButton( | ||
436 | + backgroundColor: Colors.red, | ||
437 | + onPressed: () { | ||
438 | + isVideo = true; | ||
439 | + _onImageButtonPressed(ImageSource.camera, context: context); | ||
440 | + }, | ||
441 | + heroTag: 'video1', | ||
442 | + tooltip: 'Take a Video', | ||
443 | + child: const Icon(Icons.videocam), | ||
444 | + ), | ||
445 | + ), | ||
446 | + ], | ||
447 | + ), | ||
448 | + ); | ||
449 | + } | ||
450 | + | ||
451 | + Text? _getRetrieveErrorWidget() { | ||
452 | + if (_retrieveDataError != null) { | ||
453 | + final Text result = Text(_retrieveDataError!); | ||
454 | + _retrieveDataError = null; | ||
455 | + return result; | ||
456 | + } | ||
457 | + return null; | ||
458 | + } | ||
459 | + | ||
460 | + Future<void> _displayPickImageDialog( | ||
461 | + BuildContext context, OnPickImageCallback onPick) async { | ||
462 | + return showDialog( | ||
463 | + context: context, | ||
464 | + builder: (BuildContext context) { | ||
465 | + return AlertDialog( | ||
466 | + title: const Text('Add optional parameters'), | ||
467 | + content: Column( | ||
468 | + children: <Widget>[ | ||
469 | + TextField( | ||
470 | + controller: maxWidthController, | ||
471 | + keyboardType: | ||
472 | + const TextInputType.numberWithOptions(decimal: true), | ||
473 | + decoration: const InputDecoration( | ||
474 | + hintText: 'Enter maxWidth if desired'), | ||
475 | + ), | ||
476 | + TextField( | ||
477 | + controller: maxHeightController, | ||
478 | + keyboardType: | ||
479 | + const TextInputType.numberWithOptions(decimal: true), | ||
480 | + decoration: const InputDecoration( | ||
481 | + hintText: 'Enter maxHeight if desired'), | ||
482 | + ), | ||
483 | + TextField( | ||
484 | + controller: qualityController, | ||
485 | + keyboardType: TextInputType.number, | ||
486 | + decoration: const InputDecoration( | ||
487 | + hintText: 'Enter quality if desired'), | ||
488 | + ), | ||
489 | + ], | ||
490 | + ), | ||
491 | + actions: <Widget>[ | ||
492 | + TextButton( | ||
493 | + child: const Text('CANCEL'), | ||
494 | + onPressed: () { | ||
495 | + Navigator.of(context).pop(); | ||
496 | + }, | ||
497 | + ), | ||
498 | + TextButton( | ||
499 | + child: const Text('PICK'), | ||
500 | + onPressed: () { | ||
501 | + final double? width = maxWidthController.text.isNotEmpty | ||
502 | + ? double.parse(maxWidthController.text) | ||
503 | + : null; | ||
504 | + final double? height = maxHeightController.text.isNotEmpty | ||
505 | + ? double.parse(maxHeightController.text) | ||
506 | + : null; | ||
507 | + final int? quality = qualityController.text.isNotEmpty | ||
508 | + ? int.parse(qualityController.text) | ||
509 | + : null; | ||
510 | + onPick(width, height, quality); | ||
511 | + Navigator.of(context).pop(); | ||
512 | + }), | ||
513 | + ], | ||
514 | + ); | ||
515 | + }); | ||
516 | + } | ||
517 | +} | ||
518 | + | ||
519 | +typedef OnPickImageCallback = void Function( | ||
520 | + double? maxWidth, double? maxHeight, int? quality); | ||
521 | + | ||
522 | +class AspectRatioVideo extends StatefulWidget { | ||
523 | + const AspectRatioVideo(this.controller, {super.key}); | ||
524 | + | ||
525 | + final VideoPlayerController? controller; | ||
526 | + | ||
527 | + @override | ||
528 | + AspectRatioVideoState createState() => AspectRatioVideoState(); | ||
529 | +} | ||
530 | + | ||
531 | +class AspectRatioVideoState extends State<AspectRatioVideo> { | ||
532 | + VideoPlayerController? get controller => widget.controller; | ||
533 | + bool initialized = false; | ||
534 | + | ||
535 | + void _onVideoControllerUpdate() { | ||
536 | + if (!mounted) { | ||
537 | + return; | ||
538 | + } | ||
539 | + if (initialized != controller!.value.isInitialized) { | ||
540 | + initialized = controller!.value.isInitialized; | ||
541 | + setState(() {}); | ||
542 | + } | ||
543 | + } | ||
544 | + | ||
545 | + @override | ||
546 | + void initState() { | ||
547 | + super.initState(); | ||
548 | + controller!.addListener(_onVideoControllerUpdate); | ||
549 | + } | ||
550 | + | ||
551 | + @override | ||
552 | + void dispose() { | ||
553 | + controller!.removeListener(_onVideoControllerUpdate); | ||
554 | + super.dispose(); | ||
555 | + } | ||
556 | + | ||
557 | + @override | ||
558 | + Widget build(BuildContext context) { | ||
559 | + if (initialized) { | ||
560 | + return Center( | ||
561 | + child: AspectRatio( | ||
562 | + aspectRatio: controller!.value.aspectRatio, | ||
563 | + child: VideoPlayer(controller!), | ||
564 | + ), | ||
565 | + ); | ||
566 | + } else { | ||
567 | + return Container(); | ||
568 | + } | ||
569 | + } | ||
570 | +} |
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +import 'package:flutter/services.dart'; | ||
6 | +import 'package:image_picker/image_picker.dart'; | ||
7 | +// #docregion CameraDelegate | ||
8 | +import 'package:image_picker_platform_interface/image_picker_platform_interface.dart'; | ||
9 | +// #enddocregion CameraDelegate | ||
10 | + | ||
11 | +/// Example of a camera delegate | ||
12 | +// #docregion CameraDelegate | ||
13 | +class MyCameraDelegate extends ImagePickerCameraDelegate { | ||
14 | + @override | ||
15 | + Future<XFile?> takePhoto( | ||
16 | + {ImagePickerCameraDelegateOptions options = | ||
17 | + const ImagePickerCameraDelegateOptions()}) async { | ||
18 | + return _takeAPhoto(options.preferredCameraDevice); | ||
19 | + } | ||
20 | + | ||
21 | + @override | ||
22 | + Future<XFile?> takeVideo( | ||
23 | + {ImagePickerCameraDelegateOptions options = | ||
24 | + const ImagePickerCameraDelegateOptions()}) async { | ||
25 | + return _takeAVideo(options.preferredCameraDevice); | ||
26 | + } | ||
27 | +} | ||
28 | +// #enddocregion CameraDelegate | ||
29 | + | ||
30 | +/// Example function for README demonstration of various pick* calls. | ||
31 | +Future<List<XFile?>> readmePickExample() async { | ||
32 | + // #docregion Pick | ||
33 | + final ImagePicker picker = ImagePicker(); | ||
34 | + // Pick an image. | ||
35 | + final XFile? image = await picker.pickImage(source: ImageSource.gallery); | ||
36 | + // Capture a photo. | ||
37 | + final XFile? photo = await picker.pickImage(source: ImageSource.camera); | ||
38 | + // Pick a video. | ||
39 | + final XFile? galleryVideo = | ||
40 | + await picker.pickVideo(source: ImageSource.gallery); | ||
41 | + // Capture a video. | ||
42 | + final XFile? cameraVideo = await picker.pickVideo(source: ImageSource.camera); | ||
43 | + // Pick multiple images. | ||
44 | + final List<XFile> images = await picker.pickMultiImage(); | ||
45 | + // Pick singe image or video. | ||
46 | + final XFile? media = await picker.pickMedia(); | ||
47 | + // Pick multiple images and videos. | ||
48 | + final List<XFile> medias = await picker.pickMultipleMedia(); | ||
49 | + // #enddocregion Pick | ||
50 | + | ||
51 | + // Return everything for the sanity check test. | ||
52 | + return <XFile?>[ | ||
53 | + image, | ||
54 | + photo, | ||
55 | + galleryVideo, | ||
56 | + cameraVideo, | ||
57 | + if (images.isEmpty) null else images.first, | ||
58 | + media, | ||
59 | + if (medias.isEmpty) null else medias.first, | ||
60 | + ]; | ||
61 | +} | ||
62 | + | ||
63 | +/// Example function for README demonstration of getting lost data. | ||
64 | +// #docregion LostData | ||
65 | +Future<void> getLostData() async { | ||
66 | + final ImagePicker picker = ImagePicker(); | ||
67 | + final LostDataResponse response = await picker.retrieveLostData(); | ||
68 | + if (response.isEmpty) { | ||
69 | + return; | ||
70 | + } | ||
71 | + final List<XFile>? files = response.files; | ||
72 | + if (files != null) { | ||
73 | + _handleLostFiles(files); | ||
74 | + } else { | ||
75 | + _handleError(response.exception); | ||
76 | + } | ||
77 | +} | ||
78 | +// #enddocregion LostData | ||
79 | + | ||
80 | +/// Example of camera delegate setup. | ||
81 | +// #docregion CameraDelegate | ||
82 | +void setUpCameraDelegate() { | ||
83 | + final ImagePickerPlatform instance = ImagePickerPlatform.instance; | ||
84 | + if (instance is CameraDelegatingImagePickerPlatform) { | ||
85 | + instance.cameraDelegate = MyCameraDelegate(); | ||
86 | + } | ||
87 | +} | ||
88 | +// #enddocregion CameraDelegate | ||
89 | + | ||
90 | +// Stubs for the getLostData function. | ||
91 | +void _handleLostFiles(List<XFile> file) {} | ||
92 | +void _handleError(PlatformException? exception) {} | ||
93 | + | ||
94 | +// Stubs for MyCameraDelegate. | ||
95 | +Future<XFile?> _takeAPhoto(CameraDevice device) async => null; | ||
96 | +Future<XFile?> _takeAVideo(CameraDevice device) async => null; |
image_picker/example/linux/.gitignore
0 → 100644
1 | +flutter/ephemeral |
image_picker/example/linux/CMakeLists.txt
0 → 100644
1 | +# Project-level configuration. | ||
2 | +cmake_minimum_required(VERSION 3.10) | ||
3 | +project(runner LANGUAGES CXX) | ||
4 | + | ||
5 | +# The name of the executable created for the application. Change this to change | ||
6 | +# the on-disk name of your application. | ||
7 | +set(BINARY_NAME "image_picker_example") | ||
8 | +# The unique GTK application identifier for this application. See: | ||
9 | +# https://wiki.gnome.org/HowDoI/ChooseApplicationID | ||
10 | +set(APPLICATION_ID "dev.flutter.plugins.image_picker_example") | ||
11 | + | ||
12 | +# Explicitly opt in to modern CMake behaviors to avoid warnings with recent | ||
13 | +# versions of CMake. | ||
14 | +cmake_policy(SET CMP0063 NEW) | ||
15 | + | ||
16 | +# Load bundled libraries from the lib/ directory relative to the binary. | ||
17 | +set(CMAKE_INSTALL_RPATH "$ORIGIN/lib") | ||
18 | + | ||
19 | +# Root filesystem for cross-building. | ||
20 | +if(FLUTTER_TARGET_PLATFORM_SYSROOT) | ||
21 | + set(CMAKE_SYSROOT ${FLUTTER_TARGET_PLATFORM_SYSROOT}) | ||
22 | + set(CMAKE_FIND_ROOT_PATH ${CMAKE_SYSROOT}) | ||
23 | + set(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER) | ||
24 | + set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY) | ||
25 | + set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) | ||
26 | + set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) | ||
27 | +endif() | ||
28 | + | ||
29 | +# Define build configuration options. | ||
30 | +if(NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES) | ||
31 | + set(CMAKE_BUILD_TYPE "Debug" CACHE | ||
32 | + STRING "Flutter build mode" FORCE) | ||
33 | + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS | ||
34 | + "Debug" "Profile" "Release") | ||
35 | +endif() | ||
36 | + | ||
37 | +# Compilation settings that should be applied to most targets. | ||
38 | +# | ||
39 | +# Be cautious about adding new options here, as plugins use this function by | ||
40 | +# default. In most cases, you should add new options to specific targets instead | ||
41 | +# of modifying this function. | ||
42 | +function(APPLY_STANDARD_SETTINGS TARGET) | ||
43 | + target_compile_features(${TARGET} PUBLIC cxx_std_14) | ||
44 | + target_compile_options(${TARGET} PRIVATE -Wall -Werror) | ||
45 | + target_compile_options(${TARGET} PRIVATE "$<$<NOT:$<CONFIG:Debug>>:-O3>") | ||
46 | + target_compile_definitions(${TARGET} PRIVATE "$<$<NOT:$<CONFIG:Debug>>:NDEBUG>") | ||
47 | +endfunction() | ||
48 | + | ||
49 | +# Flutter library and tool build rules. | ||
50 | +set(FLUTTER_MANAGED_DIR "${CMAKE_CURRENT_SOURCE_DIR}/flutter") | ||
51 | +add_subdirectory(${FLUTTER_MANAGED_DIR}) | ||
52 | + | ||
53 | +# System-level dependencies. | ||
54 | +find_package(PkgConfig REQUIRED) | ||
55 | +pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0) | ||
56 | + | ||
57 | +add_definitions(-DAPPLICATION_ID="${APPLICATION_ID}") | ||
58 | + | ||
59 | +# Define the application target. To change its name, change BINARY_NAME above, | ||
60 | +# not the value here, or `flutter run` will no longer work. | ||
61 | +# | ||
62 | +# Any new source files that you add to the application should be added here. | ||
63 | +add_executable(${BINARY_NAME} | ||
64 | + "main.cc" | ||
65 | + "my_application.cc" | ||
66 | + "${FLUTTER_MANAGED_DIR}/generated_plugin_registrant.cc" | ||
67 | +) | ||
68 | + | ||
69 | +# Apply the standard set of build settings. This can be removed for applications | ||
70 | +# that need different build settings. | ||
71 | +apply_standard_settings(${BINARY_NAME}) | ||
72 | + | ||
73 | +# Add dependency libraries. Add any application-specific dependencies here. | ||
74 | +target_link_libraries(${BINARY_NAME} PRIVATE flutter) | ||
75 | +target_link_libraries(${BINARY_NAME} PRIVATE PkgConfig::GTK) | ||
76 | + | ||
77 | +# Run the Flutter tool portions of the build. This must not be removed. | ||
78 | +add_dependencies(${BINARY_NAME} flutter_assemble) | ||
79 | + | ||
80 | +# Only the install-generated bundle's copy of the executable will launch | ||
81 | +# correctly, since the resources must in the right relative locations. To avoid | ||
82 | +# people trying to run the unbundled copy, put it in a subdirectory instead of | ||
83 | +# the default top-level location. | ||
84 | +set_target_properties(${BINARY_NAME} | ||
85 | + PROPERTIES | ||
86 | + RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/intermediates_do_not_run" | ||
87 | +) | ||
88 | + | ||
89 | +# Generated plugin build rules, which manage building the plugins and adding | ||
90 | +# them to the application. | ||
91 | +include(flutter/generated_plugins.cmake) | ||
92 | + | ||
93 | + | ||
94 | +# === Installation === | ||
95 | +# By default, "installing" just makes a relocatable bundle in the build | ||
96 | +# directory. | ||
97 | +set(BUILD_BUNDLE_DIR "${PROJECT_BINARY_DIR}/bundle") | ||
98 | +if(CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT) | ||
99 | + set(CMAKE_INSTALL_PREFIX "${BUILD_BUNDLE_DIR}" CACHE PATH "..." FORCE) | ||
100 | +endif() | ||
101 | + | ||
102 | +# Start with a clean build bundle directory every time. | ||
103 | +install(CODE " | ||
104 | + file(REMOVE_RECURSE \"${BUILD_BUNDLE_DIR}/\") | ||
105 | + " COMPONENT Runtime) | ||
106 | + | ||
107 | +set(INSTALL_BUNDLE_DATA_DIR "${CMAKE_INSTALL_PREFIX}/data") | ||
108 | +set(INSTALL_BUNDLE_LIB_DIR "${CMAKE_INSTALL_PREFIX}/lib") | ||
109 | + | ||
110 | +install(TARGETS ${BINARY_NAME} RUNTIME DESTINATION "${CMAKE_INSTALL_PREFIX}" | ||
111 | + COMPONENT Runtime) | ||
112 | + | ||
113 | +install(FILES "${FLUTTER_ICU_DATA_FILE}" DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" | ||
114 | + COMPONENT Runtime) | ||
115 | + | ||
116 | +install(FILES "${FLUTTER_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" | ||
117 | + COMPONENT Runtime) | ||
118 | + | ||
119 | +foreach(bundled_library ${PLUGIN_BUNDLED_LIBRARIES}) | ||
120 | + install(FILES "${bundled_library}" | ||
121 | + DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" | ||
122 | + COMPONENT Runtime) | ||
123 | +endforeach(bundled_library) | ||
124 | + | ||
125 | +# Fully re-copy the assets directory on each build to avoid having stale files | ||
126 | +# from a previous install. | ||
127 | +set(FLUTTER_ASSET_DIR_NAME "flutter_assets") | ||
128 | +install(CODE " | ||
129 | + file(REMOVE_RECURSE \"${INSTALL_BUNDLE_DATA_DIR}/${FLUTTER_ASSET_DIR_NAME}\") | ||
130 | + " COMPONENT Runtime) | ||
131 | +install(DIRECTORY "${PROJECT_BUILD_DIR}/${FLUTTER_ASSET_DIR_NAME}" | ||
132 | + DESTINATION "${INSTALL_BUNDLE_DATA_DIR}" COMPONENT Runtime) | ||
133 | + | ||
134 | +# Install the AOT library on non-Debug builds only. | ||
135 | +if(NOT CMAKE_BUILD_TYPE MATCHES "Debug") | ||
136 | + install(FILES "${AOT_LIBRARY}" DESTINATION "${INSTALL_BUNDLE_LIB_DIR}" | ||
137 | + COMPONENT Runtime) | ||
138 | +endif() |
1 | +# This file controls Flutter-level build steps. It should not be edited. | ||
2 | +cmake_minimum_required(VERSION 3.10) | ||
3 | + | ||
4 | +set(EPHEMERAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/ephemeral") | ||
5 | + | ||
6 | +# Configuration provided via flutter tool. | ||
7 | +include(${EPHEMERAL_DIR}/generated_config.cmake) | ||
8 | + | ||
9 | +# TODO: Move the rest of this into files in ephemeral. See | ||
10 | +# https://github.com/flutter/flutter/issues/57146. | ||
11 | + | ||
12 | +# Serves the same purpose as list(TRANSFORM ... PREPEND ...), | ||
13 | +# which isn't available in 3.10. | ||
14 | +function(list_prepend LIST_NAME PREFIX) | ||
15 | + set(NEW_LIST "") | ||
16 | + foreach(element ${${LIST_NAME}}) | ||
17 | + list(APPEND NEW_LIST "${PREFIX}${element}") | ||
18 | + endforeach(element) | ||
19 | + set(${LIST_NAME} "${NEW_LIST}" PARENT_SCOPE) | ||
20 | +endfunction() | ||
21 | + | ||
22 | +# === Flutter Library === | ||
23 | +# System-level dependencies. | ||
24 | +find_package(PkgConfig REQUIRED) | ||
25 | +pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0) | ||
26 | +pkg_check_modules(GLIB REQUIRED IMPORTED_TARGET glib-2.0) | ||
27 | +pkg_check_modules(GIO REQUIRED IMPORTED_TARGET gio-2.0) | ||
28 | + | ||
29 | +set(FLUTTER_LIBRARY "${EPHEMERAL_DIR}/libflutter_linux_gtk.so") | ||
30 | + | ||
31 | +# Published to parent scope for install step. | ||
32 | +set(FLUTTER_LIBRARY ${FLUTTER_LIBRARY} PARENT_SCOPE) | ||
33 | +set(FLUTTER_ICU_DATA_FILE "${EPHEMERAL_DIR}/icudtl.dat" PARENT_SCOPE) | ||
34 | +set(PROJECT_BUILD_DIR "${PROJECT_DIR}/build/" PARENT_SCOPE) | ||
35 | +set(AOT_LIBRARY "${PROJECT_DIR}/build/lib/libapp.so" PARENT_SCOPE) | ||
36 | + | ||
37 | +list(APPEND FLUTTER_LIBRARY_HEADERS | ||
38 | + "fl_basic_message_channel.h" | ||
39 | + "fl_binary_codec.h" | ||
40 | + "fl_binary_messenger.h" | ||
41 | + "fl_dart_project.h" | ||
42 | + "fl_engine.h" | ||
43 | + "fl_json_message_codec.h" | ||
44 | + "fl_json_method_codec.h" | ||
45 | + "fl_message_codec.h" | ||
46 | + "fl_method_call.h" | ||
47 | + "fl_method_channel.h" | ||
48 | + "fl_method_codec.h" | ||
49 | + "fl_method_response.h" | ||
50 | + "fl_plugin_registrar.h" | ||
51 | + "fl_plugin_registry.h" | ||
52 | + "fl_standard_message_codec.h" | ||
53 | + "fl_standard_method_codec.h" | ||
54 | + "fl_string_codec.h" | ||
55 | + "fl_value.h" | ||
56 | + "fl_view.h" | ||
57 | + "flutter_linux.h" | ||
58 | +) | ||
59 | +list_prepend(FLUTTER_LIBRARY_HEADERS "${EPHEMERAL_DIR}/flutter_linux/") | ||
60 | +add_library(flutter INTERFACE) | ||
61 | +target_include_directories(flutter INTERFACE | ||
62 | + "${EPHEMERAL_DIR}" | ||
63 | +) | ||
64 | +target_link_libraries(flutter INTERFACE "${FLUTTER_LIBRARY}") | ||
65 | +target_link_libraries(flutter INTERFACE | ||
66 | + PkgConfig::GTK | ||
67 | + PkgConfig::GLIB | ||
68 | + PkgConfig::GIO | ||
69 | +) | ||
70 | +add_dependencies(flutter flutter_assemble) | ||
71 | + | ||
72 | +# === Flutter tool backend === | ||
73 | +# _phony_ is a non-existent file to force this command to run every time, | ||
74 | +# since currently there's no way to get a full input/output list from the | ||
75 | +# flutter tool. | ||
76 | +add_custom_command( | ||
77 | + OUTPUT ${FLUTTER_LIBRARY} ${FLUTTER_LIBRARY_HEADERS} | ||
78 | + ${CMAKE_CURRENT_BINARY_DIR}/_phony_ | ||
79 | + COMMAND ${CMAKE_COMMAND} -E env | ||
80 | + ${FLUTTER_TOOL_ENVIRONMENT} | ||
81 | + "${FLUTTER_ROOT}/packages/flutter_tools/bin/tool_backend.sh" | ||
82 | + ${FLUTTER_TARGET_PLATFORM} ${CMAKE_BUILD_TYPE} | ||
83 | + VERBATIM | ||
84 | +) | ||
85 | +add_custom_target(flutter_assemble DEPENDS | ||
86 | + "${FLUTTER_LIBRARY}" | ||
87 | + ${FLUTTER_LIBRARY_HEADERS} | ||
88 | +) |
1 | +# | ||
2 | +# Generated file, do not edit. | ||
3 | +# | ||
4 | + | ||
5 | +list(APPEND FLUTTER_PLUGIN_LIST | ||
6 | + file_selector_linux | ||
7 | +) | ||
8 | + | ||
9 | +list(APPEND FLUTTER_FFI_PLUGIN_LIST | ||
10 | +) | ||
11 | + | ||
12 | +set(PLUGIN_BUNDLED_LIBRARIES) | ||
13 | + | ||
14 | +foreach(plugin ${FLUTTER_PLUGIN_LIST}) | ||
15 | + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${plugin}/linux plugins/${plugin}) | ||
16 | + target_link_libraries(${BINARY_NAME} PRIVATE ${plugin}_plugin) | ||
17 | + list(APPEND PLUGIN_BUNDLED_LIBRARIES $<TARGET_FILE:${plugin}_plugin>) | ||
18 | + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${plugin}_bundled_libraries}) | ||
19 | +endforeach(plugin) | ||
20 | + | ||
21 | +foreach(ffi_plugin ${FLUTTER_FFI_PLUGIN_LIST}) | ||
22 | + add_subdirectory(flutter/ephemeral/.plugin_symlinks/${ffi_plugin}/linux plugins/${ffi_plugin}) | ||
23 | + list(APPEND PLUGIN_BUNDLED_LIBRARIES ${${ffi_plugin}_bundled_libraries}) | ||
24 | +endforeach(ffi_plugin) |
image_picker/example/linux/main.cc
0 → 100644
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +#include "my_application.h" | ||
6 | + | ||
7 | +int main(int argc, char** argv) { | ||
8 | + g_autoptr(MyApplication) app = my_application_new(); | ||
9 | + return g_application_run(G_APPLICATION(app), argc, argv); | ||
10 | +} |
image_picker/example/linux/my_application.cc
0 → 100644
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +#include "my_application.h" | ||
6 | + | ||
7 | +#include <flutter_linux/flutter_linux.h> | ||
8 | +#ifdef GDK_WINDOWING_X11 | ||
9 | +#include <gdk/gdkx.h> | ||
10 | +#endif | ||
11 | + | ||
12 | +#include "flutter/generated_plugin_registrant.h" | ||
13 | + | ||
14 | +struct _MyApplication { | ||
15 | + GtkApplication parent_instance; | ||
16 | + char** dart_entrypoint_arguments; | ||
17 | +}; | ||
18 | + | ||
19 | +G_DEFINE_TYPE(MyApplication, my_application, GTK_TYPE_APPLICATION) | ||
20 | + | ||
21 | +// Implements GApplication::activate. | ||
22 | +static void my_application_activate(GApplication* application) { | ||
23 | + MyApplication* self = MY_APPLICATION(application); | ||
24 | + GtkWindow* window = | ||
25 | + GTK_WINDOW(gtk_application_window_new(GTK_APPLICATION(application))); | ||
26 | + | ||
27 | + // Use a header bar when running in GNOME as this is the common style used | ||
28 | + // by applications and is the setup most users will be using (e.g. Ubuntu | ||
29 | + // desktop). | ||
30 | + // If running on X and not using GNOME then just use a traditional title bar | ||
31 | + // in case the window manager does more exotic layout, e.g. tiling. | ||
32 | + // If running on Wayland assume the header bar will work (may need changing | ||
33 | + // if future cases occur). | ||
34 | + gboolean use_header_bar = TRUE; | ||
35 | +#ifdef GDK_WINDOWING_X11 | ||
36 | + GdkScreen* screen = gtk_window_get_screen(window); | ||
37 | + if (GDK_IS_X11_SCREEN(screen)) { | ||
38 | + const gchar* wm_name = gdk_x11_screen_get_window_manager_name(screen); | ||
39 | + if (g_strcmp0(wm_name, "GNOME Shell") != 0) { | ||
40 | + use_header_bar = FALSE; | ||
41 | + } | ||
42 | + } | ||
43 | +#endif | ||
44 | + if (use_header_bar) { | ||
45 | + GtkHeaderBar* header_bar = GTK_HEADER_BAR(gtk_header_bar_new()); | ||
46 | + gtk_widget_show(GTK_WIDGET(header_bar)); | ||
47 | + gtk_header_bar_set_title(header_bar, "image_picker_example"); | ||
48 | + gtk_header_bar_set_show_close_button(header_bar, TRUE); | ||
49 | + gtk_window_set_titlebar(window, GTK_WIDGET(header_bar)); | ||
50 | + } else { | ||
51 | + gtk_window_set_title(window, "image_picker_example"); | ||
52 | + } | ||
53 | + | ||
54 | + gtk_window_set_default_size(window, 1280, 720); | ||
55 | + gtk_widget_show(GTK_WIDGET(window)); | ||
56 | + | ||
57 | + g_autoptr(FlDartProject) project = fl_dart_project_new(); | ||
58 | + fl_dart_project_set_dart_entrypoint_arguments( | ||
59 | + project, self->dart_entrypoint_arguments); | ||
60 | + | ||
61 | + FlView* view = fl_view_new(project); | ||
62 | + gtk_widget_show(GTK_WIDGET(view)); | ||
63 | + gtk_container_add(GTK_CONTAINER(window), GTK_WIDGET(view)); | ||
64 | + | ||
65 | + fl_register_plugins(FL_PLUGIN_REGISTRY(view)); | ||
66 | + | ||
67 | + gtk_widget_grab_focus(GTK_WIDGET(view)); | ||
68 | +} | ||
69 | + | ||
70 | +// Implements GApplication::local_command_line. | ||
71 | +static gboolean my_application_local_command_line(GApplication* application, | ||
72 | + gchar*** arguments, | ||
73 | + int* exit_status) { | ||
74 | + MyApplication* self = MY_APPLICATION(application); | ||
75 | + // Strip out the first argument as it is the binary name. | ||
76 | + self->dart_entrypoint_arguments = g_strdupv(*arguments + 1); | ||
77 | + | ||
78 | + g_autoptr(GError) error = nullptr; | ||
79 | + if (!g_application_register(application, nullptr, &error)) { | ||
80 | + g_warning("Failed to register: %s", error->message); | ||
81 | + *exit_status = 1; | ||
82 | + return TRUE; | ||
83 | + } | ||
84 | + | ||
85 | + g_application_activate(application); | ||
86 | + *exit_status = 0; | ||
87 | + | ||
88 | + return TRUE; | ||
89 | +} | ||
90 | + | ||
91 | +// Implements GObject::dispose. | ||
92 | +static void my_application_dispose(GObject* object) { | ||
93 | + MyApplication* self = MY_APPLICATION(object); | ||
94 | + g_clear_pointer(&self->dart_entrypoint_arguments, g_strfreev); | ||
95 | + G_OBJECT_CLASS(my_application_parent_class)->dispose(object); | ||
96 | +} | ||
97 | + | ||
98 | +static void my_application_class_init(MyApplicationClass* klass) { | ||
99 | + G_APPLICATION_CLASS(klass)->activate = my_application_activate; | ||
100 | + G_APPLICATION_CLASS(klass)->local_command_line = | ||
101 | + my_application_local_command_line; | ||
102 | + G_OBJECT_CLASS(klass)->dispose = my_application_dispose; | ||
103 | +} | ||
104 | + | ||
105 | +static void my_application_init(MyApplication* self) {} | ||
106 | + | ||
107 | +MyApplication* my_application_new() { | ||
108 | + return MY_APPLICATION(g_object_new(my_application_get_type(), | ||
109 | + "application-id", APPLICATION_ID, "flags", | ||
110 | + G_APPLICATION_NON_UNIQUE, nullptr)); | ||
111 | +} |
image_picker/example/linux/my_application.h
0 → 100644
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +#ifndef FLUTTER_MY_APPLICATION_H_ | ||
6 | +#define FLUTTER_MY_APPLICATION_H_ | ||
7 | + | ||
8 | +#include <gtk/gtk.h> | ||
9 | + | ||
10 | +G_DECLARE_FINAL_TYPE(MyApplication, my_application, MY, APPLICATION, | ||
11 | + GtkApplication) | ||
12 | + | ||
13 | +/** | ||
14 | + * my_application_new: | ||
15 | + * | ||
16 | + * Creates a new Flutter-based application. | ||
17 | + * | ||
18 | + * Returns: a new #MyApplication. | ||
19 | + */ | ||
20 | +MyApplication* my_application_new(); | ||
21 | + | ||
22 | +#endif // FLUTTER_MY_APPLICATION_H_ |
image_picker/example/macos/.gitignore
0 → 100644
image_picker/example/macos/Podfile
0 → 100644
1 | +platform :osx, '10.14' | ||
2 | + | ||
3 | +# CocoaPods analytics sends network stats synchronously affecting flutter build latency. | ||
4 | +ENV['COCOAPODS_DISABLE_STATS'] = 'true' | ||
5 | + | ||
6 | +project 'Runner', { | ||
7 | + 'Debug' => :debug, | ||
8 | + 'Profile' => :release, | ||
9 | + 'Release' => :release, | ||
10 | +} | ||
11 | + | ||
12 | +def flutter_root | ||
13 | + generated_xcode_build_settings_path = File.expand_path(File.join('..', 'Flutter', 'ephemeral', 'Flutter-Generated.xcconfig'), __FILE__) | ||
14 | + unless File.exist?(generated_xcode_build_settings_path) | ||
15 | + raise "#{generated_xcode_build_settings_path} must exist. If you're running pod install manually, make sure \"flutter pub get\" is executed first" | ||
16 | + end | ||
17 | + | ||
18 | + File.foreach(generated_xcode_build_settings_path) do |line| | ||
19 | + matches = line.match(/FLUTTER_ROOT\=(.*)/) | ||
20 | + return matches[1].strip if matches | ||
21 | + end | ||
22 | + raise "FLUTTER_ROOT not found in #{generated_xcode_build_settings_path}. Try deleting Flutter-Generated.xcconfig, then run \"flutter pub get\"" | ||
23 | +end | ||
24 | + | ||
25 | +require File.expand_path(File.join('packages', 'flutter_tools', 'bin', 'podhelper'), flutter_root) | ||
26 | + | ||
27 | +flutter_macos_podfile_setup | ||
28 | + | ||
29 | +target 'Runner' do | ||
30 | + use_frameworks! | ||
31 | + use_modular_headers! | ||
32 | + | ||
33 | + flutter_install_all_macos_pods File.dirname(File.realpath(__FILE__)) | ||
34 | +end | ||
35 | + | ||
36 | +post_install do |installer| | ||
37 | + installer.pods_project.targets.each do |target| | ||
38 | + flutter_additional_macos_build_settings(target) | ||
39 | + end | ||
40 | +end |
1 | +// !$*UTF8*$! | ||
2 | +{ | ||
3 | + archiveVersion = 1; | ||
4 | + classes = { | ||
5 | + }; | ||
6 | + objectVersion = 54; | ||
7 | + objects = { | ||
8 | + | ||
9 | +/* Begin PBXAggregateTarget section */ | ||
10 | + 33CC111A2044C6BA0003C045 /* Flutter Assemble */ = { | ||
11 | + isa = PBXAggregateTarget; | ||
12 | + buildConfigurationList = 33CC111B2044C6BA0003C045 /* Build configuration list for PBXAggregateTarget "Flutter Assemble" */; | ||
13 | + buildPhases = ( | ||
14 | + 33CC111E2044C6BF0003C045 /* ShellScript */, | ||
15 | + ); | ||
16 | + dependencies = ( | ||
17 | + ); | ||
18 | + name = "Flutter Assemble"; | ||
19 | + productName = FLX; | ||
20 | + }; | ||
21 | +/* End PBXAggregateTarget section */ | ||
22 | + | ||
23 | +/* Begin PBXBuildFile section */ | ||
24 | + 335BBD1B22A9A15E00E9071D /* GeneratedPluginRegistrant.swift in Sources */ = {isa = PBXBuildFile; fileRef = 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */; }; | ||
25 | + 33CC10F12044A3C60003C045 /* AppDelegate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC10F02044A3C60003C045 /* AppDelegate.swift */; }; | ||
26 | + 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F22044A3C60003C045 /* Assets.xcassets */; }; | ||
27 | + 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 33CC10F42044A3C60003C045 /* MainMenu.xib */; }; | ||
28 | + 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */ = {isa = PBXBuildFile; fileRef = 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */; }; | ||
29 | +/* End PBXBuildFile section */ | ||
30 | + | ||
31 | +/* Begin PBXContainerItemProxy section */ | ||
32 | + 33CC111F2044C79F0003C045 /* PBXContainerItemProxy */ = { | ||
33 | + isa = PBXContainerItemProxy; | ||
34 | + containerPortal = 33CC10E52044A3C60003C045 /* Project object */; | ||
35 | + proxyType = 1; | ||
36 | + remoteGlobalIDString = 33CC111A2044C6BA0003C045; | ||
37 | + remoteInfo = FLX; | ||
38 | + }; | ||
39 | +/* End PBXContainerItemProxy section */ | ||
40 | + | ||
41 | +/* Begin PBXCopyFilesBuildPhase section */ | ||
42 | + 33CC110E2044A8840003C045 /* Bundle Framework */ = { | ||
43 | + isa = PBXCopyFilesBuildPhase; | ||
44 | + buildActionMask = 2147483647; | ||
45 | + dstPath = ""; | ||
46 | + dstSubfolderSpec = 10; | ||
47 | + files = ( | ||
48 | + ); | ||
49 | + name = "Bundle Framework"; | ||
50 | + runOnlyForDeploymentPostprocessing = 0; | ||
51 | + }; | ||
52 | +/* End PBXCopyFilesBuildPhase section */ | ||
53 | + | ||
54 | +/* Begin PBXFileReference section */ | ||
55 | + 333000ED22D3DE5D00554162 /* Warnings.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Warnings.xcconfig; sourceTree = "<group>"; }; | ||
56 | + 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = GeneratedPluginRegistrant.swift; sourceTree = "<group>"; }; | ||
57 | + 33CC10ED2044A3C60003C045 /* image_picker_example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "image_picker_example.app"; sourceTree = BUILT_PRODUCTS_DIR; }; | ||
58 | + 33CC10F02044A3C60003C045 /* AppDelegate.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = AppDelegate.swift; sourceTree = "<group>"; }; | ||
59 | + 33CC10F22044A3C60003C045 /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Assets.xcassets; path = Runner/Assets.xcassets; sourceTree = "<group>"; }; | ||
60 | + 33CC10F52044A3C60003C045 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/MainMenu.xib; sourceTree = "<group>"; }; | ||
61 | + 33CC10F72044A3C60003C045 /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; name = Info.plist; path = Runner/Info.plist; sourceTree = "<group>"; }; | ||
62 | + 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = MainFlutterWindow.swift; sourceTree = "<group>"; }; | ||
63 | + 33CEB47222A05771004F2AC0 /* Flutter-Debug.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = "Flutter-Debug.xcconfig"; sourceTree = "<group>"; }; | ||
64 | + 33CEB47422A05771004F2AC0 /* Flutter-Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = "Flutter-Release.xcconfig"; sourceTree = "<group>"; }; | ||
65 | + 33CEB47722A0578A004F2AC0 /* Flutter-Generated.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; name = "Flutter-Generated.xcconfig"; path = "ephemeral/Flutter-Generated.xcconfig"; sourceTree = "<group>"; }; | ||
66 | + 33E51913231747F40026EE4D /* DebugProfile.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = DebugProfile.entitlements; sourceTree = "<group>"; }; | ||
67 | + 33E51914231749380026EE4D /* Release.entitlements */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.entitlements; path = Release.entitlements; sourceTree = "<group>"; }; | ||
68 | + 33E5194F232828860026EE4D /* AppInfo.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = AppInfo.xcconfig; sourceTree = "<group>"; }; | ||
69 | + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */ = {isa = PBXFileReference; lastKnownFileType = text.xcconfig; path = Release.xcconfig; sourceTree = "<group>"; }; | ||
70 | + 9740EEB21CF90195004384FC /* Debug.xcconfig */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.xcconfig; path = Debug.xcconfig; sourceTree = "<group>"; }; | ||
71 | +/* End PBXFileReference section */ | ||
72 | + | ||
73 | +/* Begin PBXFrameworksBuildPhase section */ | ||
74 | + 33CC10EA2044A3C60003C045 /* Frameworks */ = { | ||
75 | + isa = PBXFrameworksBuildPhase; | ||
76 | + buildActionMask = 2147483647; | ||
77 | + files = ( | ||
78 | + ); | ||
79 | + runOnlyForDeploymentPostprocessing = 0; | ||
80 | + }; | ||
81 | +/* End PBXFrameworksBuildPhase section */ | ||
82 | + | ||
83 | +/* Begin PBXGroup section */ | ||
84 | + 33BA886A226E78AF003329D5 /* Configs */ = { | ||
85 | + isa = PBXGroup; | ||
86 | + children = ( | ||
87 | + 33E5194F232828860026EE4D /* AppInfo.xcconfig */, | ||
88 | + 9740EEB21CF90195004384FC /* Debug.xcconfig */, | ||
89 | + 7AFA3C8E1D35360C0083082E /* Release.xcconfig */, | ||
90 | + 333000ED22D3DE5D00554162 /* Warnings.xcconfig */, | ||
91 | + ); | ||
92 | + path = Configs; | ||
93 | + sourceTree = "<group>"; | ||
94 | + }; | ||
95 | + 33CC10E42044A3C60003C045 = { | ||
96 | + isa = PBXGroup; | ||
97 | + children = ( | ||
98 | + 33FAB671232836740065AC1E /* Runner */, | ||
99 | + 33CEB47122A05771004F2AC0 /* Flutter */, | ||
100 | + 33CC10EE2044A3C60003C045 /* Products */, | ||
101 | + D73912EC22F37F3D000D13A0 /* Frameworks */, | ||
102 | + ); | ||
103 | + sourceTree = "<group>"; | ||
104 | + }; | ||
105 | + 33CC10EE2044A3C60003C045 /* Products */ = { | ||
106 | + isa = PBXGroup; | ||
107 | + children = ( | ||
108 | + 33CC10ED2044A3C60003C045 /* image_picker_example.app */, | ||
109 | + ); | ||
110 | + name = Products; | ||
111 | + sourceTree = "<group>"; | ||
112 | + }; | ||
113 | + 33CC11242044D66E0003C045 /* Resources */ = { | ||
114 | + isa = PBXGroup; | ||
115 | + children = ( | ||
116 | + 33CC10F22044A3C60003C045 /* Assets.xcassets */, | ||
117 | + 33CC10F42044A3C60003C045 /* MainMenu.xib */, | ||
118 | + 33CC10F72044A3C60003C045 /* Info.plist */, | ||
119 | + ); | ||
120 | + name = Resources; | ||
121 | + path = ..; | ||
122 | + sourceTree = "<group>"; | ||
123 | + }; | ||
124 | + 33CEB47122A05771004F2AC0 /* Flutter */ = { | ||
125 | + isa = PBXGroup; | ||
126 | + children = ( | ||
127 | + 335BBD1A22A9A15E00E9071D /* GeneratedPluginRegistrant.swift */, | ||
128 | + 33CEB47222A05771004F2AC0 /* Flutter-Debug.xcconfig */, | ||
129 | + 33CEB47422A05771004F2AC0 /* Flutter-Release.xcconfig */, | ||
130 | + 33CEB47722A0578A004F2AC0 /* Flutter-Generated.xcconfig */, | ||
131 | + ); | ||
132 | + path = Flutter; | ||
133 | + sourceTree = "<group>"; | ||
134 | + }; | ||
135 | + 33FAB671232836740065AC1E /* Runner */ = { | ||
136 | + isa = PBXGroup; | ||
137 | + children = ( | ||
138 | + 33CC10F02044A3C60003C045 /* AppDelegate.swift */, | ||
139 | + 33CC11122044BFA00003C045 /* MainFlutterWindow.swift */, | ||
140 | + 33E51913231747F40026EE4D /* DebugProfile.entitlements */, | ||
141 | + 33E51914231749380026EE4D /* Release.entitlements */, | ||
142 | + 33CC11242044D66E0003C045 /* Resources */, | ||
143 | + 33BA886A226E78AF003329D5 /* Configs */, | ||
144 | + ); | ||
145 | + path = Runner; | ||
146 | + sourceTree = "<group>"; | ||
147 | + }; | ||
148 | + D73912EC22F37F3D000D13A0 /* Frameworks */ = { | ||
149 | + isa = PBXGroup; | ||
150 | + children = ( | ||
151 | + ); | ||
152 | + name = Frameworks; | ||
153 | + sourceTree = "<group>"; | ||
154 | + }; | ||
155 | +/* End PBXGroup section */ | ||
156 | + | ||
157 | +/* Begin PBXNativeTarget section */ | ||
158 | + 33CC10EC2044A3C60003C045 /* Runner */ = { | ||
159 | + isa = PBXNativeTarget; | ||
160 | + buildConfigurationList = 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */; | ||
161 | + buildPhases = ( | ||
162 | + 33CC10E92044A3C60003C045 /* Sources */, | ||
163 | + 33CC10EA2044A3C60003C045 /* Frameworks */, | ||
164 | + 33CC10EB2044A3C60003C045 /* Resources */, | ||
165 | + 33CC110E2044A8840003C045 /* Bundle Framework */, | ||
166 | + 3399D490228B24CF009A79C7 /* ShellScript */, | ||
167 | + ); | ||
168 | + buildRules = ( | ||
169 | + ); | ||
170 | + dependencies = ( | ||
171 | + 33CC11202044C79F0003C045 /* PBXTargetDependency */, | ||
172 | + ); | ||
173 | + name = Runner; | ||
174 | + productName = Runner; | ||
175 | + productReference = 33CC10ED2044A3C60003C045 /* image_picker_example.app */; | ||
176 | + productType = "com.apple.product-type.application"; | ||
177 | + }; | ||
178 | +/* End PBXNativeTarget section */ | ||
179 | + | ||
180 | +/* Begin PBXProject section */ | ||
181 | + 33CC10E52044A3C60003C045 /* Project object */ = { | ||
182 | + isa = PBXProject; | ||
183 | + attributes = { | ||
184 | + LastSwiftUpdateCheck = 0920; | ||
185 | + LastUpgradeCheck = 1300; | ||
186 | + ORGANIZATIONNAME = ""; | ||
187 | + TargetAttributes = { | ||
188 | + 33CC10EC2044A3C60003C045 = { | ||
189 | + CreatedOnToolsVersion = 9.2; | ||
190 | + LastSwiftMigration = 1100; | ||
191 | + ProvisioningStyle = Automatic; | ||
192 | + SystemCapabilities = { | ||
193 | + com.apple.Sandbox = { | ||
194 | + enabled = 1; | ||
195 | + }; | ||
196 | + }; | ||
197 | + }; | ||
198 | + 33CC111A2044C6BA0003C045 = { | ||
199 | + CreatedOnToolsVersion = 9.2; | ||
200 | + ProvisioningStyle = Manual; | ||
201 | + }; | ||
202 | + }; | ||
203 | + }; | ||
204 | + buildConfigurationList = 33CC10E82044A3C60003C045 /* Build configuration list for PBXProject "Runner" */; | ||
205 | + compatibilityVersion = "Xcode 9.3"; | ||
206 | + developmentRegion = en; | ||
207 | + hasScannedForEncodings = 0; | ||
208 | + knownRegions = ( | ||
209 | + en, | ||
210 | + Base, | ||
211 | + ); | ||
212 | + mainGroup = 33CC10E42044A3C60003C045; | ||
213 | + productRefGroup = 33CC10EE2044A3C60003C045 /* Products */; | ||
214 | + projectDirPath = ""; | ||
215 | + projectRoot = ""; | ||
216 | + targets = ( | ||
217 | + 33CC10EC2044A3C60003C045 /* Runner */, | ||
218 | + 33CC111A2044C6BA0003C045 /* Flutter Assemble */, | ||
219 | + ); | ||
220 | + }; | ||
221 | +/* End PBXProject section */ | ||
222 | + | ||
223 | +/* Begin PBXResourcesBuildPhase section */ | ||
224 | + 33CC10EB2044A3C60003C045 /* Resources */ = { | ||
225 | + isa = PBXResourcesBuildPhase; | ||
226 | + buildActionMask = 2147483647; | ||
227 | + files = ( | ||
228 | + 33CC10F32044A3C60003C045 /* Assets.xcassets in Resources */, | ||
229 | + 33CC10F62044A3C60003C045 /* MainMenu.xib in Resources */, | ||
230 | + ); | ||
231 | + runOnlyForDeploymentPostprocessing = 0; | ||
232 | + }; | ||
233 | +/* End PBXResourcesBuildPhase section */ | ||
234 | + | ||
235 | +/* Begin PBXShellScriptBuildPhase section */ | ||
236 | + 3399D490228B24CF009A79C7 /* ShellScript */ = { | ||
237 | + isa = PBXShellScriptBuildPhase; | ||
238 | + alwaysOutOfDate = 1; | ||
239 | + buildActionMask = 2147483647; | ||
240 | + files = ( | ||
241 | + ); | ||
242 | + inputFileListPaths = ( | ||
243 | + ); | ||
244 | + inputPaths = ( | ||
245 | + ); | ||
246 | + outputFileListPaths = ( | ||
247 | + ); | ||
248 | + outputPaths = ( | ||
249 | + ); | ||
250 | + runOnlyForDeploymentPostprocessing = 0; | ||
251 | + shellPath = /bin/sh; | ||
252 | + shellScript = "echo \"$PRODUCT_NAME.app\" > \"$PROJECT_DIR\"/Flutter/ephemeral/.app_filename && \"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh embed\n"; | ||
253 | + }; | ||
254 | + 33CC111E2044C6BF0003C045 /* ShellScript */ = { | ||
255 | + isa = PBXShellScriptBuildPhase; | ||
256 | + buildActionMask = 2147483647; | ||
257 | + files = ( | ||
258 | + ); | ||
259 | + inputFileListPaths = ( | ||
260 | + Flutter/ephemeral/FlutterInputs.xcfilelist, | ||
261 | + ); | ||
262 | + inputPaths = ( | ||
263 | + Flutter/ephemeral/tripwire, | ||
264 | + ); | ||
265 | + outputFileListPaths = ( | ||
266 | + Flutter/ephemeral/FlutterOutputs.xcfilelist, | ||
267 | + ); | ||
268 | + outputPaths = ( | ||
269 | + ); | ||
270 | + runOnlyForDeploymentPostprocessing = 0; | ||
271 | + shellPath = /bin/sh; | ||
272 | + shellScript = "\"$FLUTTER_ROOT\"/packages/flutter_tools/bin/macos_assemble.sh && touch Flutter/ephemeral/tripwire"; | ||
273 | + }; | ||
274 | +/* End PBXShellScriptBuildPhase section */ | ||
275 | + | ||
276 | +/* Begin PBXSourcesBuildPhase section */ | ||
277 | + 33CC10E92044A3C60003C045 /* Sources */ = { | ||
278 | + isa = PBXSourcesBuildPhase; | ||
279 | + buildActionMask = 2147483647; | ||
280 | + files = ( | ||
281 | + 33CC11132044BFA00003C045 /* MainFlutterWindow.swift in Sources */, | ||
282 | + 33CC10F12044A3C60003C045 /* AppDelegate.swift in Sources */, | ||
283 | + 335BBD1B22A9A15E00E9071D /* GeneratedPluginRegistrant.swift in Sources */, | ||
284 | + ); | ||
285 | + runOnlyForDeploymentPostprocessing = 0; | ||
286 | + }; | ||
287 | +/* End PBXSourcesBuildPhase section */ | ||
288 | + | ||
289 | +/* Begin PBXTargetDependency section */ | ||
290 | + 33CC11202044C79F0003C045 /* PBXTargetDependency */ = { | ||
291 | + isa = PBXTargetDependency; | ||
292 | + target = 33CC111A2044C6BA0003C045 /* Flutter Assemble */; | ||
293 | + targetProxy = 33CC111F2044C79F0003C045 /* PBXContainerItemProxy */; | ||
294 | + }; | ||
295 | +/* End PBXTargetDependency section */ | ||
296 | + | ||
297 | +/* Begin PBXVariantGroup section */ | ||
298 | + 33CC10F42044A3C60003C045 /* MainMenu.xib */ = { | ||
299 | + isa = PBXVariantGroup; | ||
300 | + children = ( | ||
301 | + 33CC10F52044A3C60003C045 /* Base */, | ||
302 | + ); | ||
303 | + name = MainMenu.xib; | ||
304 | + path = Runner; | ||
305 | + sourceTree = "<group>"; | ||
306 | + }; | ||
307 | +/* End PBXVariantGroup section */ | ||
308 | + | ||
309 | +/* Begin XCBuildConfiguration section */ | ||
310 | + 338D0CE9231458BD00FA5F75 /* Profile */ = { | ||
311 | + isa = XCBuildConfiguration; | ||
312 | + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; | ||
313 | + buildSettings = { | ||
314 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
315 | + CLANG_ANALYZER_NONNULL = YES; | ||
316 | + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; | ||
317 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; | ||
318 | + CLANG_CXX_LIBRARY = "libc++"; | ||
319 | + CLANG_ENABLE_MODULES = YES; | ||
320 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
321 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
322 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
323 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
324 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
325 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
326 | + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; | ||
327 | + CLANG_WARN_EMPTY_BODY = YES; | ||
328 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
329 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
330 | + CLANG_WARN_INT_CONVERSION = YES; | ||
331 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
332 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
333 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
334 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
335 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
336 | + CODE_SIGN_IDENTITY = "-"; | ||
337 | + COPY_PHASE_STRIP = NO; | ||
338 | + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; | ||
339 | + ENABLE_NS_ASSERTIONS = NO; | ||
340 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
341 | + GCC_C_LANGUAGE_STANDARD = gnu11; | ||
342 | + GCC_NO_COMMON_BLOCKS = YES; | ||
343 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
344 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
345 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
346 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
347 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
348 | + MACOSX_DEPLOYMENT_TARGET = 10.14; | ||
349 | + MTL_ENABLE_DEBUG_INFO = NO; | ||
350 | + SDKROOT = macosx; | ||
351 | + SWIFT_COMPILATION_MODE = wholemodule; | ||
352 | + SWIFT_OPTIMIZATION_LEVEL = "-O"; | ||
353 | + }; | ||
354 | + name = Profile; | ||
355 | + }; | ||
356 | + 338D0CEA231458BD00FA5F75 /* Profile */ = { | ||
357 | + isa = XCBuildConfiguration; | ||
358 | + baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */; | ||
359 | + buildSettings = { | ||
360 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
361 | + CLANG_ENABLE_MODULES = YES; | ||
362 | + CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements; | ||
363 | + CODE_SIGN_STYLE = Automatic; | ||
364 | + COMBINE_HIDPI_IMAGES = YES; | ||
365 | + INFOPLIST_FILE = Runner/Info.plist; | ||
366 | + LD_RUNPATH_SEARCH_PATHS = ( | ||
367 | + "$(inherited)", | ||
368 | + "@executable_path/../Frameworks", | ||
369 | + ); | ||
370 | + PROVISIONING_PROFILE_SPECIFIER = ""; | ||
371 | + SWIFT_VERSION = 5.0; | ||
372 | + }; | ||
373 | + name = Profile; | ||
374 | + }; | ||
375 | + 338D0CEB231458BD00FA5F75 /* Profile */ = { | ||
376 | + isa = XCBuildConfiguration; | ||
377 | + buildSettings = { | ||
378 | + CODE_SIGN_STYLE = Manual; | ||
379 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
380 | + }; | ||
381 | + name = Profile; | ||
382 | + }; | ||
383 | + 33CC10F92044A3C60003C045 /* Debug */ = { | ||
384 | + isa = XCBuildConfiguration; | ||
385 | + baseConfigurationReference = 9740EEB21CF90195004384FC /* Debug.xcconfig */; | ||
386 | + buildSettings = { | ||
387 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
388 | + CLANG_ANALYZER_NONNULL = YES; | ||
389 | + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; | ||
390 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; | ||
391 | + CLANG_CXX_LIBRARY = "libc++"; | ||
392 | + CLANG_ENABLE_MODULES = YES; | ||
393 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
394 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
395 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
396 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
397 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
398 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
399 | + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; | ||
400 | + CLANG_WARN_EMPTY_BODY = YES; | ||
401 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
402 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
403 | + CLANG_WARN_INT_CONVERSION = YES; | ||
404 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
405 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
406 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
407 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
408 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
409 | + CODE_SIGN_IDENTITY = "-"; | ||
410 | + COPY_PHASE_STRIP = NO; | ||
411 | + DEBUG_INFORMATION_FORMAT = dwarf; | ||
412 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
413 | + ENABLE_TESTABILITY = YES; | ||
414 | + GCC_C_LANGUAGE_STANDARD = gnu11; | ||
415 | + GCC_DYNAMIC_NO_PIC = NO; | ||
416 | + GCC_NO_COMMON_BLOCKS = YES; | ||
417 | + GCC_OPTIMIZATION_LEVEL = 0; | ||
418 | + GCC_PREPROCESSOR_DEFINITIONS = ( | ||
419 | + "DEBUG=1", | ||
420 | + "$(inherited)", | ||
421 | + ); | ||
422 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
423 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
424 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
425 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
426 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
427 | + MACOSX_DEPLOYMENT_TARGET = 10.14; | ||
428 | + MTL_ENABLE_DEBUG_INFO = YES; | ||
429 | + ONLY_ACTIVE_ARCH = YES; | ||
430 | + SDKROOT = macosx; | ||
431 | + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; | ||
432 | + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; | ||
433 | + }; | ||
434 | + name = Debug; | ||
435 | + }; | ||
436 | + 33CC10FA2044A3C60003C045 /* Release */ = { | ||
437 | + isa = XCBuildConfiguration; | ||
438 | + baseConfigurationReference = 7AFA3C8E1D35360C0083082E /* Release.xcconfig */; | ||
439 | + buildSettings = { | ||
440 | + ALWAYS_SEARCH_USER_PATHS = NO; | ||
441 | + CLANG_ANALYZER_NONNULL = YES; | ||
442 | + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; | ||
443 | + CLANG_CXX_LANGUAGE_STANDARD = "gnu++14"; | ||
444 | + CLANG_CXX_LIBRARY = "libc++"; | ||
445 | + CLANG_ENABLE_MODULES = YES; | ||
446 | + CLANG_ENABLE_OBJC_ARC = YES; | ||
447 | + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; | ||
448 | + CLANG_WARN_BOOL_CONVERSION = YES; | ||
449 | + CLANG_WARN_CONSTANT_CONVERSION = YES; | ||
450 | + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; | ||
451 | + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; | ||
452 | + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; | ||
453 | + CLANG_WARN_EMPTY_BODY = YES; | ||
454 | + CLANG_WARN_ENUM_CONVERSION = YES; | ||
455 | + CLANG_WARN_INFINITE_RECURSION = YES; | ||
456 | + CLANG_WARN_INT_CONVERSION = YES; | ||
457 | + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; | ||
458 | + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; | ||
459 | + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; | ||
460 | + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; | ||
461 | + CLANG_WARN_SUSPICIOUS_MOVE = YES; | ||
462 | + CODE_SIGN_IDENTITY = "-"; | ||
463 | + COPY_PHASE_STRIP = NO; | ||
464 | + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; | ||
465 | + ENABLE_NS_ASSERTIONS = NO; | ||
466 | + ENABLE_STRICT_OBJC_MSGSEND = YES; | ||
467 | + GCC_C_LANGUAGE_STANDARD = gnu11; | ||
468 | + GCC_NO_COMMON_BLOCKS = YES; | ||
469 | + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; | ||
470 | + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; | ||
471 | + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; | ||
472 | + GCC_WARN_UNUSED_FUNCTION = YES; | ||
473 | + GCC_WARN_UNUSED_VARIABLE = YES; | ||
474 | + MACOSX_DEPLOYMENT_TARGET = 10.14; | ||
475 | + MTL_ENABLE_DEBUG_INFO = NO; | ||
476 | + SDKROOT = macosx; | ||
477 | + SWIFT_COMPILATION_MODE = wholemodule; | ||
478 | + SWIFT_OPTIMIZATION_LEVEL = "-O"; | ||
479 | + }; | ||
480 | + name = Release; | ||
481 | + }; | ||
482 | + 33CC10FC2044A3C60003C045 /* Debug */ = { | ||
483 | + isa = XCBuildConfiguration; | ||
484 | + baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */; | ||
485 | + buildSettings = { | ||
486 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
487 | + CLANG_ENABLE_MODULES = YES; | ||
488 | + CODE_SIGN_ENTITLEMENTS = Runner/DebugProfile.entitlements; | ||
489 | + CODE_SIGN_STYLE = Automatic; | ||
490 | + COMBINE_HIDPI_IMAGES = YES; | ||
491 | + INFOPLIST_FILE = Runner/Info.plist; | ||
492 | + LD_RUNPATH_SEARCH_PATHS = ( | ||
493 | + "$(inherited)", | ||
494 | + "@executable_path/../Frameworks", | ||
495 | + ); | ||
496 | + PROVISIONING_PROFILE_SPECIFIER = ""; | ||
497 | + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; | ||
498 | + SWIFT_VERSION = 5.0; | ||
499 | + }; | ||
500 | + name = Debug; | ||
501 | + }; | ||
502 | + 33CC10FD2044A3C60003C045 /* Release */ = { | ||
503 | + isa = XCBuildConfiguration; | ||
504 | + baseConfigurationReference = 33E5194F232828860026EE4D /* AppInfo.xcconfig */; | ||
505 | + buildSettings = { | ||
506 | + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; | ||
507 | + CLANG_ENABLE_MODULES = YES; | ||
508 | + CODE_SIGN_ENTITLEMENTS = Runner/Release.entitlements; | ||
509 | + CODE_SIGN_STYLE = Automatic; | ||
510 | + COMBINE_HIDPI_IMAGES = YES; | ||
511 | + INFOPLIST_FILE = Runner/Info.plist; | ||
512 | + LD_RUNPATH_SEARCH_PATHS = ( | ||
513 | + "$(inherited)", | ||
514 | + "@executable_path/../Frameworks", | ||
515 | + ); | ||
516 | + PROVISIONING_PROFILE_SPECIFIER = ""; | ||
517 | + SWIFT_VERSION = 5.0; | ||
518 | + }; | ||
519 | + name = Release; | ||
520 | + }; | ||
521 | + 33CC111C2044C6BA0003C045 /* Debug */ = { | ||
522 | + isa = XCBuildConfiguration; | ||
523 | + buildSettings = { | ||
524 | + CODE_SIGN_STYLE = Manual; | ||
525 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
526 | + }; | ||
527 | + name = Debug; | ||
528 | + }; | ||
529 | + 33CC111D2044C6BA0003C045 /* Release */ = { | ||
530 | + isa = XCBuildConfiguration; | ||
531 | + buildSettings = { | ||
532 | + CODE_SIGN_STYLE = Automatic; | ||
533 | + PRODUCT_NAME = "$(TARGET_NAME)"; | ||
534 | + }; | ||
535 | + name = Release; | ||
536 | + }; | ||
537 | +/* End XCBuildConfiguration section */ | ||
538 | + | ||
539 | +/* Begin XCConfigurationList section */ | ||
540 | + 33CC10E82044A3C60003C045 /* Build configuration list for PBXProject "Runner" */ = { | ||
541 | + isa = XCConfigurationList; | ||
542 | + buildConfigurations = ( | ||
543 | + 33CC10F92044A3C60003C045 /* Debug */, | ||
544 | + 33CC10FA2044A3C60003C045 /* Release */, | ||
545 | + 338D0CE9231458BD00FA5F75 /* Profile */, | ||
546 | + ); | ||
547 | + defaultConfigurationIsVisible = 0; | ||
548 | + defaultConfigurationName = Release; | ||
549 | + }; | ||
550 | + 33CC10FB2044A3C60003C045 /* Build configuration list for PBXNativeTarget "Runner" */ = { | ||
551 | + isa = XCConfigurationList; | ||
552 | + buildConfigurations = ( | ||
553 | + 33CC10FC2044A3C60003C045 /* Debug */, | ||
554 | + 33CC10FD2044A3C60003C045 /* Release */, | ||
555 | + 338D0CEA231458BD00FA5F75 /* Profile */, | ||
556 | + ); | ||
557 | + defaultConfigurationIsVisible = 0; | ||
558 | + defaultConfigurationName = Release; | ||
559 | + }; | ||
560 | + 33CC111B2044C6BA0003C045 /* Build configuration list for PBXAggregateTarget "Flutter Assemble" */ = { | ||
561 | + isa = XCConfigurationList; | ||
562 | + buildConfigurations = ( | ||
563 | + 33CC111C2044C6BA0003C045 /* Debug */, | ||
564 | + 33CC111D2044C6BA0003C045 /* Release */, | ||
565 | + 338D0CEB231458BD00FA5F75 /* Profile */, | ||
566 | + ); | ||
567 | + defaultConfigurationIsVisible = 0; | ||
568 | + defaultConfigurationName = Release; | ||
569 | + }; | ||
570 | +/* End XCConfigurationList section */ | ||
571 | + }; | ||
572 | + rootObject = 33CC10E52044A3C60003C045 /* Project object */; | ||
573 | +} |
1 | +<?xml version="1.0" encoding="UTF-8"?> | ||
2 | +<Scheme | ||
3 | + LastUpgradeVersion = "1300" | ||
4 | + version = "1.3"> | ||
5 | + <BuildAction | ||
6 | + parallelizeBuildables = "YES" | ||
7 | + buildImplicitDependencies = "YES"> | ||
8 | + <BuildActionEntries> | ||
9 | + <BuildActionEntry | ||
10 | + buildForTesting = "YES" | ||
11 | + buildForRunning = "YES" | ||
12 | + buildForProfiling = "YES" | ||
13 | + buildForArchiving = "YES" | ||
14 | + buildForAnalyzing = "YES"> | ||
15 | + <BuildableReference | ||
16 | + BuildableIdentifier = "primary" | ||
17 | + BlueprintIdentifier = "33CC10EC2044A3C60003C045" | ||
18 | + BuildableName = "image_picker_example.app" | ||
19 | + BlueprintName = "Runner" | ||
20 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
21 | + </BuildableReference> | ||
22 | + </BuildActionEntry> | ||
23 | + </BuildActionEntries> | ||
24 | + </BuildAction> | ||
25 | + <TestAction | ||
26 | + buildConfiguration = "Debug" | ||
27 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
28 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
29 | + shouldUseLaunchSchemeArgsEnv = "YES"> | ||
30 | + <MacroExpansion> | ||
31 | + <BuildableReference | ||
32 | + BuildableIdentifier = "primary" | ||
33 | + BlueprintIdentifier = "33CC10EC2044A3C60003C045" | ||
34 | + BuildableName = "image_picker_example.app" | ||
35 | + BlueprintName = "Runner" | ||
36 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
37 | + </BuildableReference> | ||
38 | + </MacroExpansion> | ||
39 | + <Testables> | ||
40 | + </Testables> | ||
41 | + </TestAction> | ||
42 | + <LaunchAction | ||
43 | + buildConfiguration = "Debug" | ||
44 | + selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB" | ||
45 | + selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB" | ||
46 | + launchStyle = "0" | ||
47 | + useCustomWorkingDirectory = "NO" | ||
48 | + ignoresPersistentStateOnLaunch = "NO" | ||
49 | + debugDocumentVersioning = "YES" | ||
50 | + debugServiceExtension = "internal" | ||
51 | + allowLocationSimulation = "YES"> | ||
52 | + <BuildableProductRunnable | ||
53 | + runnableDebuggingMode = "0"> | ||
54 | + <BuildableReference | ||
55 | + BuildableIdentifier = "primary" | ||
56 | + BlueprintIdentifier = "33CC10EC2044A3C60003C045" | ||
57 | + BuildableName = "image_picker_example.app" | ||
58 | + BlueprintName = "Runner" | ||
59 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
60 | + </BuildableReference> | ||
61 | + </BuildableProductRunnable> | ||
62 | + </LaunchAction> | ||
63 | + <ProfileAction | ||
64 | + buildConfiguration = "Profile" | ||
65 | + shouldUseLaunchSchemeArgsEnv = "YES" | ||
66 | + savedToolIdentifier = "" | ||
67 | + useCustomWorkingDirectory = "NO" | ||
68 | + debugDocumentVersioning = "YES"> | ||
69 | + <BuildableProductRunnable | ||
70 | + runnableDebuggingMode = "0"> | ||
71 | + <BuildableReference | ||
72 | + BuildableIdentifier = "primary" | ||
73 | + BlueprintIdentifier = "33CC10EC2044A3C60003C045" | ||
74 | + BuildableName = "image_picker_example.app" | ||
75 | + BlueprintName = "Runner" | ||
76 | + ReferencedContainer = "container:Runner.xcodeproj"> | ||
77 | + </BuildableReference> | ||
78 | + </BuildableProductRunnable> | ||
79 | + </ProfileAction> | ||
80 | + <AnalyzeAction | ||
81 | + buildConfiguration = "Debug"> | ||
82 | + </AnalyzeAction> | ||
83 | + <ArchiveAction | ||
84 | + buildConfiguration = "Release" | ||
85 | + revealArchiveInOrganizer = "YES"> | ||
86 | + </ArchiveAction> | ||
87 | +</Scheme> |
1 | +// Copyright 2013 The Flutter Authors. All rights reserved. | ||
2 | +// Use of this source code is governed by a BSD-style license that can be | ||
3 | +// found in the LICENSE file. | ||
4 | + | ||
5 | +import Cocoa | ||
6 | +import FlutterMacOS | ||
7 | + | ||
8 | +@NSApplicationMain | ||
9 | +class AppDelegate: FlutterAppDelegate { | ||
10 | + override func applicationShouldTerminateAfterLastWindowClosed(_ sender: NSApplication) -> Bool { | ||
11 | + return true | ||
12 | + } | ||
13 | +} |
1 | +{ | ||
2 | + "images" : [ | ||
3 | + { | ||
4 | + "size" : "16x16", | ||
5 | + "idiom" : "mac", | ||
6 | + "filename" : "app_icon_16.png", | ||
7 | + "scale" : "1x" | ||
8 | + }, | ||
9 | + { | ||
10 | + "size" : "16x16", | ||
11 | + "idiom" : "mac", | ||
12 | + "filename" : "app_icon_32.png", | ||
13 | + "scale" : "2x" | ||
14 | + }, | ||
15 | + { | ||
16 | + "size" : "32x32", | ||
17 | + "idiom" : "mac", | ||
18 | + "filename" : "app_icon_32.png", | ||
19 | + "scale" : "1x" | ||
20 | + }, | ||
21 | + { | ||
22 | + "size" : "32x32", | ||
23 | + "idiom" : "mac", | ||
24 | + "filename" : "app_icon_64.png", | ||
25 | + "scale" : "2x" | ||
26 | + }, | ||
27 | + { | ||
28 | + "size" : "128x128", | ||
29 | + "idiom" : "mac", | ||
30 | + "filename" : "app_icon_128.png", | ||
31 | + "scale" : "1x" | ||
32 | + }, | ||
33 | + { | ||
34 | + "size" : "128x128", | ||
35 | + "idiom" : "mac", | ||
36 | + "filename" : "app_icon_256.png", | ||
37 | + "scale" : "2x" | ||
38 | + }, | ||
39 | + { | ||
40 | + "size" : "256x256", | ||
41 | + "idiom" : "mac", | ||
42 | + "filename" : "app_icon_256.png", | ||
43 | + "scale" : "1x" | ||
44 | + }, | ||
45 | + { | ||
46 | + "size" : "256x256", | ||
47 | + "idiom" : "mac", | ||
48 | + "filename" : "app_icon_512.png", | ||
49 | + "scale" : "2x" | ||
50 | + }, | ||
51 | + { | ||
52 | + "size" : "512x512", | ||
53 | + "idiom" : "mac", | ||
54 | + "filename" : "app_icon_512.png", | ||
55 | + "scale" : "1x" | ||
56 | + }, | ||
57 | + { | ||
58 | + "size" : "512x512", | ||
59 | + "idiom" : "mac", | ||
60 | + "filename" : "app_icon_1024.png", | ||
61 | + "scale" : "2x" | ||
62 | + } | ||
63 | + ], | ||
64 | + "info" : { | ||
65 | + "version" : 1, | ||
66 | + "author" : "xcode" | ||
67 | + } | ||
68 | +} |

101 KB

5.55 KB

520 Bytes

13.8 KB

1.04 KB

35.6 KB
-
Please register or login to post a comment