[英]How to show Default Android Messages like (+) button and show custom widget in place of keyboard in flutter?
When you tap on + button, what happens is,当您点击+按钮时,会发生什么,
Keyboard Closed, to achieve this you can use FocusNode
instance and assign in TextField
, to unfocus or to close keyboard, you can achieve it by focusNode.unfocus()
.键盘关闭,为此您可以使用FocusNode
实例并在TextField
中分配,以取消焦点或关闭键盘,您可以通过focusNode.unfocus()
来实现。
The content you see on tap of + is outside keyboard, ie you have to create widget and change it's visibility accordingly, Visibility
can be used.您点击+看到的内容在键盘之外,即您必须创建小部件并相应地更改它的可见性,可以使用Visibility
。
In other case misc options is visible and user tap on keyboard icon then change visibility of extra options and obtain focus of FocusNode
instance(enable keyboard), by focusNode.requestFocus()
.在其他情况下,杂项选项可见,用户点击键盘图标,然后通过focusNode.requestFocus()
更改额外选项的可见性并获得FocusNode
实例的焦点(启用键盘)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.