繁体   English   中英

将ipad连接到蓝牙键盘时,ios的隐藏栏(在底部)

[英]Hide bar (at the bottom) of ios when connect ipad to bluetooth keyboard

嗨,我正在为ios设备(ipad)开发phonegap / cordova项目。 该应用程序通过蓝牙键盘接收输入文本(因为我不想在屏幕上显示键盘)。 到目前为止,应用程序可以按预期接收输入。但是关于外观,如何删除或隐藏屏幕底部的栏? (请在下面的链接中查看图片)

https://www.dropbox.com/sh/rt5w3ccqomec335/AADKUvt0w6KigfADAsx-ciu_a?dl=0

这是我的代码

config.xml文件:

<preference name="KeyboardDisplayRequiresUserAction" value="false" />

HTML:

<div style="overflow: hidden; position: relative; width: 1px; height: 1px; left: -500px">
     <input id="input" type="textfield" autocorrect="off" autocapitalize="off">
</div>

JS:

document.getElementById('input').focus();

非常感谢你的帮助!

将此插件安装到您的项目中: https : //github.com/driftyco/ionic-plugin-keyboard

并在JS中使用它: cordova.plugins.Keyboard.hideKeyboardAccessoryBar(true); 文档详细信息: https : //github.com/driftyco/ionic-plugin-keyboard#keyboardhidekeyboardaccessorybar

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM