admin管理员组文章数量:1303353
I have a screen. There is a TextField on it, with onTapOutside=(){} (to not lose focus) and keyboard type set to none. And there is custom inapp onscreen keyboard.
I need a way to simulate key events when tapping keys on the keyboard.
I tried HardwareKeyboard.instance.handleKeyEvent. I tried KeyEventSimulator from flutter_test package, with removing TestAsyncUtils.guard and TestDefaultBinaryMessengerBinding changing to ServicesBinding.
I expected the characters to appear in the input field.
本文标签: flutterIs there any way to simulate keyboard eventsStack Overflow
版权声明:本文标题:flutter - Is there any way to simulate keyboard events? - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1741749284a2395726.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论