suragch / mongol

Mongolian vertical script widgets for Flutter apps
https://pub.dev/packages/mongol
BSD 3-Clause "New" or "Revised" License
70 stars 15 forks source link

Bug: unable to move MongolTextField caret by tapping (iOS) #12

Closed leovinsen closed 3 years ago

leovinsen commented 3 years ago

Hi @suragch, I believe there's a bug in the latest version that affects only ios devices.

Issue Description

Version: 2.0.1 (running on Flutter 2.2.2) Bug: Unable to move MongolTextField cursor caret by tapping with finger (on physical device) / clicking with mouse (on simulator).

On Android it's working normally (Tested on emulator Nexus 5S API 25)

Expected Behavior

Able to move cursor caret by tapping / clicking. Previously it was working in version 1.1.0 (running on Flutter 2.0.6)

Actual Behavior

Unable to move cursor caret by tapping / clicking. Can still move by long clicking

Steps to Reproduce

Minimal reproducible code can be found at: https://github.com/leovinsen/mongol_flutter_bug

  1. Run the flutter app
  2. It will show a MongolTextField filled with pre-defined text.
  3. Tapping on anywhere on the textfield does not move the caret. However, long tapping / holding still works.

My Environment

suragch commented 3 years ago

Nicely done on your bug notification! Very professional. I'll take a look and fix the issue as soon as possible.

suragch commented 3 years ago

Ok, this should be fixed in version 2.0.2. Let me know if that works for you.

suragch commented 3 years ago

Normally iOS should behave a little differently than Android (select the word edge rather than exactly when the tap location occurred), but I disabled that functionality so Android and iOS both behave the same for taps. I'm still not sure what the original reason was for tap not working on iOS, though.

leovinsen commented 3 years ago

Thanks for your swift response! It now works for me on both simulator and physical device. I'm closing this issue.

leovinsen commented 3 years ago

Maybe something in Flutter 2.2 altered the tap functionality? Not sure either

suragch commented 3 years ago

Could be. I had to change quite a bit of the inner workings to match the Flutter 2.2 widgets.