问题:当我从平板电脑访问我的应用程序时,在playstore上收到“此应用程序可能未针对您的设备进行优化”的警告。
对于此问题,我在stackoverflow上经历了各种 questions(DUPLICATE),但是我还没有找到解决方案。因此提出了一个新问题。
我已经通过了平板电脑应用质量指南。
还已经用Google填写的“平板电脑设计”表格Link
进行了查询。这是我从Google收到的回复。
经进一步审核,我们确定您的应用程序不符合要在平板电脑设备上使用的基本平板电脑应用质量检查清单,如下所述:http://developer.android.com/distribute/googleplay/quality/tablet.html 8.正确定位Android版本 http://developer.android.com/distribute/essentials/quality/tablets.html#android-versions 9.正确声明硬件功能依赖性 http://developer.android.com/distribute/essentials/quality/tablets.html#hardware-requirements
根据建议,我已更新清单文件,并进行测试以将其发布为Playstore上的Alpha版本,但仍然在Alpha版本上得到相同的未优化警告。
这是合并清单的样子
<manifest
xmlns:android="http://schemas.android.com/apk/res/android"
android:versionCode="8010008"
android:versionName="8.1.0.8"
>
<uses-sdk
android:minSdkVersion="16"
android:targetSdkVersion="23" />
<uses-permission
android:name="android.permission.INTERNET" />
<uses-permission
android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission
android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
<uses-permission
android:name="android.permission.WAKE_LOCK" />
<uses-permission
android:name="android.permission.RECORD_AUDIO" />
<uses-permission
android:name="android.permission.CAMERA" />
<uses-permission
android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
<uses-permission
android:name="android.permission.READ_CONTACTS" />
<uses-permission
android:name="android.permission.GET_ACCOUNTS" />
<uses-permission
android:name="android.permission.ACCESS_FINE_LOCATION" />
<uses-permission
android:name="android.permission.READ_SMS" />
<uses-permission
android:name="android.permission.RECEIVE_SMS" />
<uses-permission
android:name="android.permission.SEND_SMS" />
<uses-permission
android:name="android.permission.READ_PHONE_STATE" />
<uses-feature
android:name="android.hardware.camera"
android:required="false" />
<uses-feature
android:name="android.hardware.camera.front"
android:required="false" />
<uses-feature
android:name="android.hardware.camera.autofocus"
android:required="false" />
<uses-feature
android:glEsVersion="0x20000"
android:required="true" />
<uses-feature
android:name="android.hardware.telephony"
android:required="false" />
<uses-feature
android:name="android.hardware.location.gps"
android:required="false" />
<uses-feature
android:name="android.hardware.location.network"
android:required="false" />
<uses-feature
android:name="android.hardware.microphone"
android:required="false" />
<uses-feature
android:name="android.hardware.camera.flash"
android:required="false" />
<uses-feature
android:name="android.hardware.screen.landscape"
android:required="false" />
<uses-feature
android:name="android.hardware.wifi"
android:required="false" />
<uses-permission
android:name="com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE" />
<uses-permission
android:name="com.google.android.c2dm.permission.RECEIVE" />
<permission
android:name=".permission.C2D_MESSAGE"
android:protectionLevel="0x2" />
<uses-permission
android:name=".permission.C2D_MESSAGE" />
<uses-permission
android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission
android:name="android.permission.BLUETOOTH" />
<uses-permission
android:name="android.permission.ACCESS_COARSE_LOCATION" />
下面的成绩文件:
apply plugin: 'com.android.application'
apply plugin: 'io.fabric'
buildscript {
repositories {
mavenCentral()
maven { url 'https://maven.fabric.io/public' }
}
dependencies {
classpath 'io.fabric.tools:gradle:1.25.4'
}
}
repositories {
mavenCentral()
maven { url 'https://maven.fabric.io/public' }
maven {
url 'https://maven.google.com/'
name 'Google'
}
}
android {
compileSdkVersion 26
buildToolsVersion '27.0.3'
compileOptions.encoding = 'windows-1251'//
defaultConfig {
applicationId "removed"
minSdkVersion 16
targetSdkVersion 23
versionCode removed
versionName "removed"
multiDexEnabled true
buildTypes.each {
it.buildConfigField 'String', 'removed', removed
}
}
buildTypes {
release {
minifyEnabled true
shrinkResources true
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
testImplementation 'junit:junit:4.12'
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation 'com.android.support:multidex:1.0.3'
implementation 'com.android.support:customtabs:26.1.0'
implementation 'com.android.support:design:26.1.0'
implementation('com.android.support:support-v4:26.1.0') {
exclude group: 'com.android.support', module: 'support-v4'
}
implementation('com.crashlytics.sdk.android:crashlytics:2.6.4@aar') {
transitive = true
}
implementation 'com.intuit.sdp:sdp-android:1.0.4'
implementation 'com.android.support:appcompat-v7:26.1.0'
implementation 'com.android.support:recyclerview-v7:26.1.0'
implementation 'com.android.support:cardview-v7:26.1.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.2'
implementation 'com.google.android.gms:play-services-maps:15.0.1'
implementation 'com.google.android.gms:play-services-places:15.0.1'
implementation 'com.google.android.gms:play-services-analytics:16.0.1'
implementation 'com.google.android.gms:play-services-auth:15.0.1'
implementation 'com.google.code.gson:gson:2.8.0'
implementation 'com.google.firebase:firebase-crash:16.0.1'
implementation 'com.google.firebase:firebase-core:16.0.1'
implementation 'com.google.firebase:firebase-messaging:17.1.0'
implementation 'com.github.amlcurran.showcaseview:library:5.4.3'
implementation 'com.facebook.android:facebook-android-sdk:4.28.0'
implementation 'com.intuit.sdp:sdp-android:1.0.4'
implementation 'com.squareup.picasso:picasso:2.3.4'
implementation 'com.squareup.okhttp:okhttp:2.7.2'
implementation 'com.squareup.okhttp:okhttp-urlconnection:1.6.0'
implementation 'com.android.volley:volley:1.0.0'
implementation project(':app-release')
implementation project(':SecureComponent-release')
implementation files('libs/secure-component-sdk.jar')
implementation files('libs/achartengine-1.1.0.jar')
implementation files('libs/jackson-annotations-2.1.1.jar')
implementation files('libs/jackson-core-2.1.1.jar')
implementation files('libs/jackson-databind-2.1.1.jar')
implementation 'com.jakewharton:butterknife:8.8.1'
annotationProcessor 'com.jakewharton:butterknife-compiler:8.8.1'
implementation 'com.facebook.stetho:stetho:1.5.0'
implementation 'com.facebook.stetho:stetho-okhttp:1.5.0'
implementation 'com.journeyapps:zxing-android-embedded:3.4.0'
}
apply plugin: 'com.jakewharton.butterknife'
apply plugin: 'com.google.gms.google-services'
还已经在Google控制台上检查了优化技巧,但没有推荐的技巧。
请帮助!
答案 0 :(得分:0)
您需要在 application 标记之外的 AndroidManifiedt.xml 文件中使用以下内容。默认情况下,并非所有屏幕尺寸都受支持,您需要通过在Manifiedt文件中注册来手动允许它们。
<supports-screens
android:anyDensity="true"
android:largeScreens="true"
android:normalScreens="true"
android:resizeable="true"
android:smallScreens="true"
android:xlargeScreens="true" />