其中资源结构,使用为Android平板电脑和手机? [英] Which resource structure to use for both Android tablets and mobiles?

查看:129
本文介绍了其中资源结构,使用为Android平板电脑和手机?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我更新了我的应用程序的资源,最后一次,当更高密度的设备上来。
开始画我的图标在更高的分辨率,并通过使用RES /绘,华电国际的目录结构的供应他们。

I updated my app's resources the last time when higher density devices came up. Started drawing my icons in higher resolution and supplied them through the use of the res/drawable-hdpi directory structure.

到目前为止,一切都很好。

So far, so good.

现在我想要做一些改变,采用Android平板电脑。
已经更新了一些布局,然后我慢慢明白了为什么我的图标看起来有些奇怪,我认为不错的显示上:正常的10英寸平板电脑不属于华电国际,但于mdpi因此,从从前我所有的老字号资源再-appeared!

Now I wanted to do some changes to adopt for Android tablets. Have updated a few layouts and then I slowly realized why all my icons looked somewhat strange to me on that nice display: the "normal" 10 inch tablets are not classified as hdpi, but mdpi thus all my "old" resources from former times re-appeared!

我在想:我怎么为平板电脑提供的图像?同样,一个新的目录,类似绘制大型或XLARGE?我甚至会重复我的所有相同的资源,这是愚蠢的,我也想知道我为什么要一方面是和另一屏幕尺寸...

I wonder: how am I supposed to supply images for a tablet? Again, a new directory, something like drawable-large or xlarge? Not even would I have to duplicate all my identical resources, which is stupid, I also wonder why I should classify images for mdpi/hdpi on the one hand and for screen size on the other...

什么是preferred方式,Android开发应走?

What is the preferred way that Android developers should go?

谢谢!

推荐答案

我同意你的看法!我目前使用绘制-大MDPI平板电脑和绘制,华电国际的手机。

I agree with you! I'm currently using drawable-large-mdpi for tablets and drawable-hdpi for phones.

目前,您有以下选择:

HTTP://android-developers.blogspot .COM / 2011/09 / preparing换handsets.html

http://android-developers.blogspot.com/2011/07/new-tools-for-managing-screen-sizes.html

http://developer.android.com/guide/market/发布/多apks.html

这篇关于其中资源结构,使用为Android平板电脑和手机?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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