iPhone 6.1模拟器屏幕分辨率是320x548而不是640x1136,为什么它heppend? [英] iPhone 6.1 simulator screen resolution is 320x548 instead of 640x1136, why does it heppend?

查看:795
本文介绍了iPhone 6.1模拟器屏幕分辨率是320x548而不是640x1136,为什么它heppend?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用PhoneGAP为iPhone创建应用程序。我创建640x1136分辨率的应用程序的设计。但是当我试图运行应用程序到iPhone 6.1模拟器,分辨率是320x548,而不是640x1136。我使用以下JavaScript代码检查模拟屏幕分辨率。

I create an application for iPhone using PhoneGAP. I create design of application for 640x1136 resolution. But when I tried to run application into iPhone 6.1 simulator the resolution was 320x548 instead of 640x1136. I check the simulation screen resolution using following JavaScript code.

$(#width)。text(window.innerWidth);
$(#height).text(window.innerHeight);

$("#width").text(window.innerWidth); $("#height").text(window.innerHeight);

要完成此操作,我尝试了以下步骤:

To accomplish this, I tried the following steps


  1. 在/Developer/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone Simulator.app/Contents/Resources/Devices/iPhone中编辑Info.plist文件(Retina).deviceinfo /

  1. Edit your Info.plist file in /Developer/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone Simulator.app/Contents/Resources/Devices/iPhone (Retina).deviceinfo/

在XCode中打开.plist文件,并添加以下键/值对,

Open the .plist file in XCode and add the following key/value pairs,

eagle:640
giraffe:1136

eagle : 640 giraffe:1136


  1. <
  1. Save the file and restart your simulator.

选择iPhone(Retina)查看新分辨率。

Select iPhone (Retina) to see the new resolution.

但它没有帮助。

你能帮我吗。

感谢提前
对不起我的错误英语

Thanks in advance Sorry for my bad english

推荐答案

模拟器你仍然需要选择你正在运行的硬件。当运行模拟器选择硬件 - >设备,选择正确的设备(与Retina或不匹配)进行测试。

When you run on the simulator you still need to select the "hardware" that you are running on. When running the simulator choose Hardware -> Device and select the correct device (with Retina or not) to test with.

这篇关于iPhone 6.1模拟器屏幕分辨率是320x548而不是640x1136,为什么它heppend?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆