2011-10-29 4 views
3

내 앱은 핸드셋 전용으로 설계되었지만 앱을 시장에 업로드하려고하면 내 앱이 태블릿 (xlarge)에도 표시됩니다. 의도적으로 태블릿에서 액세스 할 경우 내 앱이 시장에 표시되는 것을 원하지 않습니다.Android 앱을 핸드셋에서만 사용하려면 어떻게해야합니까?

나는 minSdkVersion 및 targetVersion 지원 및 요소를 가지고 놀아 보았습니다.

또한

<manifest ... > 
    <compatible-screens> 
     <!-- all small size screens --> 
     <screen android:screenSize="small" android:screenDensity="ldpi" /> 
     <screen android:screenSize="small" android:screenDensity="mdpi" /> 
     <screen android:screenSize="small" android:screenDensity="hdpi" /> 
     <screen android:screenSize="small" android:screenDensity="xhdpi" /> 
     <!-- all normal size screens --> 
     <screen android:screenSize="normal" android:screenDensity="ldpi" /> 
     <screen android:screenSize="normal" android:screenDensity="mdpi" /> 
     <screen android:screenSize="normal" android:screenDensity="hdpi" /> 
     <screen android:screenSize="normal" android:screenDensity="xhdpi" /> 
    </compatible-screens> 
    ... 
    <application ... > 
     ... 
    <application> 
</manifest> 

사용하여 시도하지만 오류 얻을 :

Multiple annotations found at this line:
- error: No resource identifier found for attribute 'screenDensity' in package
'android'
- error: No resource identifier found for attribute 'screenSize' in package
'android'

내가 무엇을 놓치고를?

답변

4

market filters을 사용하여 응용 프로그램에 실제로 필요한 것들을 정확하게 지정해야합니다. 휴대 전화가 필요한 기기 인 경우 <uses-feature android:name="android.hardware.telephony"/>

호환되는 화면 크기를 지정하여 태블릿을 필터링하는 것은 의미가 없습니다. 하드웨어 기능 목록은 <uses-feature>을 참조하십시오. 단순히 필터링하기 위해 요소를 추가하지 마라. 매니페스트는 애플리케이션이 작동하기 위해 필요한 것을 지정해야한다.

+0

태블릿에는 전화 서비스가 없다는 것을 고려하면이 필터를 사용하면 도움이됩니다. 그러나 앱이 작동하려면 하드웨어 구성이 필요하지 않습니다. 내 앱은 핸드셋 (소형부터 대형까지) 용으로 특별히 제작되었으며, 앱이 타블렛에서 예상대로 작동하지 않기 때문에 부정적인 리뷰를 원하지 않습니다. – sku

+0

게시 한 XML이 여기에서 잘 작동합니다. 프로젝트 구축 타겟은 무엇입니까? – user999717

+0

10 ... 이 (가) 9시에 소개되었습니다 ... – sku

1

<supports-screens> 태그 사용은 어떻습니까?

<manifest ... > 
    <supports-screens android:smallScreens="true" 
         android:normalScreens="true" 
         android:largeScreens="true" 
         android:xlargeScreens="false" 
         android:largestWidthLimitDp="600" /> 
    <application> 
    </application> 
</manifest> 

자세한 내용은 여기를 참조하십시오.

http://developer.android.com/guide/topics/manifest/supports-screens-element.html

0

나는이 그것에 대해 갈 수있는 올바른 방법 인 경우 정말 모르겠습니다. 하지만 한 번쯤은이 앱을 사용하여 태블릿 사용자가 기기에서이 애플리케이션에 액세스하지 못하도록 앱에서 사용했습니다.

+0

기기가 앱을 다운로드하여 설치 한 후에 작동 할 수 있습니다. 태블릿에서 앱을 보이지 않게하려면 필터가 필요합니다. – sku

+2

아니요,하지 마세요. Galaxy Nexus와 같이 휴대 전화와 같은 새로운 기기는 앱을 사용할 수 없습니다. – kabuko

+0

@ kabuko - 유효한 포인트를 만들기위한 +1! – Abhijit

0

재생 콘솔의 장치 카탈로그를 살펴보면 더 많은 화면 밀도 값을 지정해야합니다. (아래 참조, 오늘) 나는 항상 장치 카탈로그에 새로운 가치가 나타나게 될 위험이 있다고 생각합니다. 따라서 앱에서 지원하지 않는 기기의 양을 지속적으로 모니터링해야합니다.

<!-- Exclude Tablets --> 
<compatible-screens> 
    <!-- all small size screens --> 
    <screen android:screenSize="small" android:screenDensity="ldpi" /> 
    <screen android:screenSize="small" android:screenDensity="mdpi" /> 
    <screen android:screenSize="small" android:screenDensity="hdpi" /> 
    <screen android:screenSize="small" android:screenDensity="xhdpi" /> 
    <screen android:screenSize="small" android:screenDensity="xxhdpi" /> 
    <screen android:screenSize="small" android:screenDensity="xxxhdpi" /> 
    <screen android:screenSize="small" android:screenDensity="213" /> 
    <screen android:screenSize="small" android:screenDensity="280" /> 
    <screen android:screenSize="small" android:screenDensity="360" /> 
    <screen android:screenSize="small" android:screenDensity="400" /> 
    <screen android:screenSize="small" android:screenDensity="420" /> 
    <screen android:screenSize="small" android:screenDensity="480" /> 
    <screen android:screenSize="small" android:screenDensity="560" /> 
    <!-- all normal size screens --> 
    <screen android:screenSize="normal" android:screenDensity="ldpi" /> 
    <screen android:screenSize="normal" android:screenDensity="mdpi" /> 
    <screen android:screenSize="normal" android:screenDensity="hdpi" /> 
    <screen android:screenSize="normal" android:screenDensity="xhdpi" /> 
    <screen android:screenSize="normal" android:screenDensity="xxhdpi" /> 
    <screen android:screenSize="normal" android:screenDensity="xxxhdpi" /> 
    <screen android:screenSize="normal" android:screenDensity="213" /> 
    <screen android:screenSize="normal" android:screenDensity="280" /> 
    <screen android:screenSize="normal" android:screenDensity="360" /> 
    <screen android:screenSize="normal" android:screenDensity="400" /> 
    <screen android:screenSize="normal" android:screenDensity="420" /> 
    <screen android:screenSize="normal" android:screenDensity="480" /> 
    <screen android:screenSize="normal" android:screenDensity="560" /> 
</compatible-screens> 
관련 문제