windows phone 8 cordova viewport height issue

时间:2013-08-28 17:46:12

标签: windows-phone-8 cordova updates

我们开发了带有cordova的Windows phone 8应用程序。 它的工作正常但是在windows phone8 8.0.10328.78 发布后,页脚才会被解除。 我之前检查了代码,我将视口的高度设置为768,现在是800。

这里有什么解决方案。

3 个答案:

答案 0 :(得分:2)

我得到了这个

的解决方案

MainPage.xaml更改

shell:SystemTray.IsVisible="True"

shell:SystemTray.IsVisible="False"

答案 1 :(得分:1)

我最近遇到了这个问题,构建了一个在WebView中运行的页面。问题是视口高度...使用“height = device-height”使视口成为整个屏幕高度(减去应用托盘)。

我使用的修复是在460的高度声明一个初始值,然后在文档加载后动态替换该值。这种技术适用于所有设备(我已经测试过),包括Windows,Android和iOS。

通过下面的示例记住不要将视口元标记从其当前位置移开,JS会将头部中的第二个元标记作为目标,如果移动它,则需要相应地更新JS。

ActionController::UrlGenerationError:
     No route matches {:action=>"Invoices", :controller=>"bookings", :taxiNo=>"T2"}
     # ./spec/controllers/bookings_spec.rb:50:in `block (3 levels) in <top (required)>'

答案 2 :(得分:0)

尝试将其放入CSS:

@-ms-viewport{
    width: device-width;
    height: device-height;
}