Browse Source

fix _keyboardHeight

lucky1213 4 years ago
parent
commit
c6a0522180

+ 3
- 2
packages/zefyr/example/ios/Flutter/flutter_export_environment.sh View File

@@ -2,13 +2,14 @@
2 2
 # This is a generated file; do not edit or check into version control.
3 3
 export "FLUTTER_ROOT=/Users/imac/.fvm/versions/latest-dev"
4 4
 export "FLUTTER_APPLICATION_PATH=/Users/imac/Documents/flutter/projects/zefyr/packages/zefyr/example"
5
-export "FLUTTER_TARGET=lib/main.dart"
5
+export "FLUTTER_TARGET=/Users/imac/Documents/flutter/projects/zefyr/packages/zefyr/example/lib/main.dart"
6 6
 export "FLUTTER_BUILD_DIR=build"
7 7
 export "SYMROOT=${SOURCE_ROOT}/../build/ios"
8 8
 export "OTHER_LDFLAGS=$(inherited) -framework Flutter"
9 9
 export "FLUTTER_FRAMEWORK_DIR=/Users/imac/.fvm/versions/latest-dev/bin/cache/artifacts/engine/ios"
10 10
 export "FLUTTER_BUILD_NAME=1.0.0"
11 11
 export "FLUTTER_BUILD_NUMBER=1"
12
+export "DART_DEFINES=flutter.inspector.structuredErrors%3Dtrue"
12 13
 export "DART_OBFUSCATION=false"
13
-export "TRACK_WIDGET_CREATION=false"
14
+export "TRACK_WIDGET_CREATION=true"
14 15
 export "TREE_SHAKE_ICONS=false"

+ 4
- 4
packages/zefyr/example/ios/Podfile.lock View File

@@ -40,13 +40,13 @@ EXTERNAL SOURCES:
40 40
 
41 41
 SPEC CHECKSUMS:
42 42
   Flutter: 0e3d915762c693b495b44d77113d4970485de6ec
43
-  flutter_plugin_android_lifecycle: 47de533a02850f070f5696a623995e93eddcdb9b
44
-  image_picker: e3eacd46b94694dde7cf2705955cece853aa1a8f
43
+  flutter_plugin_android_lifecycle: dc0b544e129eebb77a6bfb1239d4d1c673a60a35
44
+  image_picker: 66aa71bc96850a90590a35d4c4a2907b0d823109
45 45
   photo_manager: f7c619c2cc8c2adb8d85c63363babac477de9c67
46
-  url_launcher: a1c0cc845906122c4784c542523d8cacbded5626
46
+  url_launcher: 6fef411d543ceb26efce54b05a0a40bfd74cbbef
47 47
   url_launcher_macos: fd7894421cd39320dce5f292fc99ea9270b2a313
48 48
   url_launcher_web: e5527357f037c87560776e36436bf2b0288b965c
49 49
 
50 50
 PODFILE CHECKSUM: 49ec7d4076524b7e225c38b98147173651ac4b9d
51 51
 
52
-COCOAPODS: 1.8.4
52
+COCOAPODS: 1.9.1

+ 0
- 8
packages/zefyr/lib/src/widgets/editor.dart View File

@@ -142,14 +142,6 @@ class _ZefyrEditorState extends State<ZefyrEditor> {
142 142
     super.initState();
143 143
     _imageDelegate = widget.imageDelegate;
144 144
     _linkDelegate = widget.linkDelegate;
145
-    WidgetsBinding.instance.addPostFrameCallback((Duration duration) {
146
-      if (MediaQuery.of(context).viewInsets.bottom == 0) {
147
-        if (!_scope.keepOverlay) {
148
-          _scope.toolbarAction = null;
149
-          hideToolbar();
150
-        }
151
-      }
152
-    });
153 145
   }
154 146
 
155 147
   @override

+ 1
- 3
packages/zefyr/lib/src/widgets/toolbar.dart View File

@@ -327,9 +327,7 @@ class ZefyrToolbarState extends State<ZefyrToolbar>
327 327
 
328 328
   @override
329 329
   Widget build(BuildContext context) {
330
-    if (MediaQuery.of(context).viewInsets.bottom > 0) {
331
-      _keyboardHeight = MediaQuery.of(context).viewInsets.bottom;
332
-    }
330
+    _keyboardHeight = MediaQuery.of(context).viewInsets.bottom;
333 331
     final theme = ZefyrTheme.of(context).toolbarTheme;
334 332
 
335 333
     final kToolbarDivider = Container(