Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

moveCursorToEnd doesn't work anymore #73

Open
mobilemindtec opened this issue Jul 14, 2021 · 0 comments
Open

moveCursorToEnd doesn't work anymore #73

mobilemindtec opened this issue Jul 14, 2021 · 0 comments

Comments

@mobilemindtec
Copy link

Hi,

I'm update android version from my project, to minSdk 20 and targetSdk 30. Apparently after this change the cursor no longer stops at the end of the text, but at the position of the mask. To fix it, I added the following code (Future.delayed) to the plugin. It worked, but I don't know if it's the best thing to do:

  @override
  void set text(String newText) {
    if (super.text != newText) {
      super.text = newText;
      Future.delayed(Duration(milliseconds: 50), this.moveCursorToEnd);
    }
  }

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant