似乎iPad规则会覆盖iPhone4相关规则。 我该如何解决这个问题?
/* iPad */
@media only screen and (min-device-width: 768px) and (max-device-width: 1024px) and (orientation:portrait) {
#theDiv { width: 400px; }
}
@media only screen and (min-device-width: 768px) and (max-device-width: 1024px) and (orientation:landscape) {
#theDiv { width: 600px; }
}
/* iPhoneRetina */
@media only screen and (-webkit-min-device-pixel-ratio : 1.5), only screen and (min-device-pixel-ratio : 1.5) {
#theDiv { width: 200px; }
}
答案 0 :(得分:1)
您可以将Retina显示像素比率提高到2。
Here's the link to the Webkit blog post about it。转到标题“条件包含”。