如何限制Android应用只有平板电脑? [英] How to restrict android apps to tablet only?

查看:156
本文介绍了如何限制Android应用只有平板电脑?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


  

我开发了针对平板电脑只不是针对手机的应用程序。这是code是足以acheive我的目标。有什么方法来测试它或Google Play排序它本身和present给用户?下面是code我都试过了。但我不知道如何测试它?


 <采用-SDK
    安卓的minSdkVersion =11
    机器人:targetSdkVersion =18/><支持屏
机器人:largeScreens =真
机器人:normalScreens =假
机器人:smallScreens =假
机器人:requiresSmallestWidthDp =600
机器人:xlargeScreens =真/>


  

的是Android:anyDensity =真,应与支持屏幕的标签一起被给予的?或者只是离开这个属性。我要努力在所有范围药片我的申请。


在这种情况下,任何帮助是非常AP preciable。感谢InAdvance。


解决方案

好像OKE,应据我所知工作。

想想你定义为平板电脑。是什么让您的应用程序不太适合一个6的手机,比7平板电脑?

您不能真正测试,直到你把它上传在谷歌Play商店。在manifest.xml这些过滤器由谷歌的Play商店安装的应用程序没有实际使用的时候,。他们只是要确保有人不找到自己的平板电脑应用程序,并安装按钮将无法在网站上正常工作。

您可以通过只上传您的APK但不能出版,我认为测试。它会给你正在使用当前设置支持的设备列表。

I am developing an app that targets for tablets only not for phones. Is this code is enough to acheive my goal. Is there any way to test it or google play sorts it's by itself and present to users?? Below is the code I have tried. But i don't know how to test it?

    <uses-sdk
    android:minSdkVersion="11"
    android:targetSdkVersion="18" />

<supports-screens
android:largeScreens="true"
android:normalScreens="false"
android:smallScreens="false"
android:requiresSmallestWidthDp="600"
android:xlargeScreens="true" />

Is android:anyDensity="true" should be given along with support screen tag? or just leave that attribute. I want to work my application on all range of tablets.

Any help in this case is highly appreciable. thanks InAdvance.

解决方案

Seems oke, should work as far as I know.

Think about what you define as a tablet. What makes your app less suitable for a 6" phone, than for a 7" tablet?

You can't really test this until you upload it in the Google play Store. These filters in the manifest.xml are used by the Google Play Store, not actually when installing an app. They just make sure somebody doesn't find the app on his tablet and the install button won't work on the website.

You could test it by just uploading your APK but not publishing I think. It will give you a list of devices that are supported with the current settings.

这篇关于如何限制Android应用只有平板电脑?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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