[英]Cordova on Android : How to stop shrinking of screen if virtual keyboard is displayed?
Helo, 喂,
I have a problem with screen shrinking on Android devices if virtual keyboard is displayed.I would like to keep screen without shrinking. 如果显示虚拟键盘,我在Android设备上的屏幕缩小有问题,我想保持屏幕不缩小。
I tried to use following setting in cordova config.xml file in the root of the project: 我尝试在项目根目录的cordova config.xml文件中使用以下设置:
<preference name="Orientation" value="portrait"/>
<preference name="KeyboardShrinksView" value="false" />
<preference name="LoadingDialog" value="My Title,My Message"/>
<preference name="DisallowOverscroll" value="false" />
<preference name="fullscreen" value="false" />
But without the luck 但是没有运气
Or set directly these attributes: 或直接设置以下属性:
android:windowSoftInputMode="adjustPan"
android:isScrollContainer="false"
Into AndroidManifest.xml file. 放入AndroidManifest.xml文件。 But in this case are changes each time overwritten by running cordova build command.
但是在这种情况下,每次运行cordova build命令都会覆盖更改。
How can i solve it please? 我该如何解决?
Thanks for any help. 谢谢你的帮助。
See image below: 见下图:
更改清单条目..它将停止屏幕缩小。
android:windowSoftInputMode="adjustNothing"
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.