Skip to content

Commit

Permalink
fix input height not returning default on clearing multi-line text
Browse files Browse the repository at this point in the history
  • Loading branch information
henryleunghk committed Dec 4, 2020
1 parent 88b71d0 commit e934666
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
"version": "0.1.1",
"version": "0.1.2",
"configurations": [
{
"name": "example",
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 0.1.2

* fix input height not returning default on clearing multi-line text

## 0.1.1

* update examples
Expand Down
5 changes: 2 additions & 3 deletions example/ios/Flutter/flutter_export_environment.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,14 @@
# This is a generated file; do not edit or check into version control.
export "FLUTTER_ROOT=/Users/henryleung/development/flutter"
export "FLUTTER_APPLICATION_PATH=/Users/henryleung/flutter-native-text-input/example"
export "FLUTTER_TARGET=/Users/henryleung/flutter-native-text-input/example/lib/main.dart"
export "FLUTTER_TARGET=lib/main.dart"
export "FLUTTER_BUILD_DIR=build"
export "SYMROOT=${SOURCE_ROOT}/../build/ios"
export "OTHER_LDFLAGS=$(inherited) -framework Flutter"
export "FLUTTER_FRAMEWORK_DIR=/Users/henryleung/development/flutter/bin/cache/artifacts/engine/ios"
export "FLUTTER_BUILD_NAME=1.0.0"
export "FLUTTER_BUILD_NUMBER=1"
export "DART_DEFINES=flutter.inspector.structuredErrors%3Dtrue"
export "DART_OBFUSCATION=false"
export "TRACK_WIDGET_CREATION=true"
export "TRACK_WIDGET_CREATION=false"
export "TREE_SHAKE_ICONS=false"
export "PACKAGE_CONFIG=.packages"
2 changes: 1 addition & 1 deletion example/ios/Podfile.lock
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
PODS:
- Flutter (1.0.0)
- flutter_native_text_input (0.1.1):
- flutter_native_text_input (0.1.2):
- Flutter

DEPENDENCIES:
Expand Down
2 changes: 1 addition & 1 deletion ios/flutter_native_text_input.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#
Pod::Spec.new do |s|
s.name = 'flutter_native_text_input'
s.version = '0.1.1'
s.version = '0.1.2'
s.summary = 'Native text input for Flutter'
s.description = <<-DESC
Native text input for Flutter
Expand Down
5 changes: 4 additions & 1 deletion lib/flutter_native_text_input.dart
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,13 @@ class _NativeTextInputState extends State<NativeTextInput> {
if (text != null) {
if (_isMultiline &&
_currentLineIndex != lineIndex &&
lineIndex <= widget.maxLines)
lineIndex <= widget.maxLines) {
setState(() {
_currentLineIndex = lineIndex;
});
} else {
_currentLineIndex = 0;
}

if (widget?.onChanged != null) widget.onChanged(text);
if (widget.controller != null) _effectiveController.text = text;
Expand Down
2 changes: 1 addition & 1 deletion pubspec.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: flutter_native_text_input
description: Native text input for Flutter. Currently iOS-only with the use of UITextView.

version: 0.1.1
version: 0.1.2
homepage: https://github.com/henryleunghk/flutter-native-text-input

environment:
Expand Down

0 comments on commit e934666

Please sign in to comment.