如何在PhoneGap中找到虚拟键盘的高度?

时间:2014-07-25 10:07:10

标签: jquery-mobile cordova

我需要在虚拟键盘正上方移动一个textarea和按钮,如下所示:

enter image description here

为此,我需要知道键盘的高度。我尝试过使用$(window).height()方法,但奇怪的是,即使键盘打开也不会改变。

有什么建议吗?

1 个答案:

答案 0 :(得分:1)

对于Iphone

iPhone 4S(及早期版)人像键盘(英文)320 x 216 pts

iPhone 4S(及更早版本)风景键盘(英文)480 x 162 pts

iPhone 5人像键盘(英文)320 x 216 pts

iPhone 5风景键盘(英文)568 x 162 pts

http://www.idev101.com/code/User_Interface/sizes.html

相关问题