Browse Source

update picked camera

lucky1213 4 years ago
parent
commit
857917063c

+ 2
- 2
packages/zefyr/lib/src/widgets/buttons.dart View File

@@ -598,8 +598,8 @@ class _ImageButtonState extends State<ImageButton> {
598 598
                                 onPressed: () async {
599 599
                                   // toolbar.editor.tapHandle =
600 600
                                   //     TapHandle.takePhoto;
601
-                                  var file = await ImagePicker.pickImage(
602
-                                      source: ImageSource.camera);
601
+                                  
602
+                                  var file = await PhotoPicker.pickCamera();
603 603
                                   if (file != null) {
604 604
                                     toolbar.closeOverlay();
605 605
                                     await toolbar

+ 0
- 1
packages/zefyr/pubspec.yaml View File

@@ -19,7 +19,6 @@ dependencies:
19 19
       path: packages/notus
20 20
   meta: ^1.1.0
21 21
   quiver_hashcode: ^2.0.0
22
-  image_picker: ^0.6.5
23 22
   photo: 
24 23
     git: 
25 24
       url: https://git.links123.net/lucky1213/mutli_image_picker.git

+ 1
- 1
packages/zefyr/test/widgets/buttons_test.dart View File

@@ -183,7 +183,7 @@ void main() {
183 183
   });
184 184
 }
185 185
 
186
-class _TestImageDelegate implements ZefyrImageDelegate<String> {
186
+class _TestImageDelegate implements ZefyrImageDelegate {
187 187
   @override
188 188
   Widget buildImage(BuildContext context, String key) {
189 189
     return Image.file(File(key));

+ 1
- 1
packages/zefyr/test/widgets/image_test.dart View File

@@ -87,7 +87,7 @@ void main() {
87 87
   });
88 88
 }
89 89
 
90
-class _TestImageDelegate implements ZefyrImageDelegate<String> {
90
+class _TestImageDelegate implements ZefyrImageDelegate {
91 91
   @override
92 92
   Widget buildImage(BuildContext context, String key) {
93 93
     return Image.file(File(key));

+ 1
- 1
packages/zefyr/test/widgets/scope_test.dart View File

@@ -74,7 +74,7 @@ void main() {
74 74
   });
75 75
 }
76 76
 
77
-class _TestImageDelegate implements ZefyrImageDelegate<String> {
77
+class _TestImageDelegate implements ZefyrImageDelegate {
78 78
   @override
79 79
   Widget buildImage(BuildContext context, String key) {
80 80
     return null;