Codenameone 代号:Android TV的一个APK清单:构建提示
这一问题涉及: 我在这里找到了一些文档: 在本文档中,有人写道,Codenameone 代号:Android TV的一个APK清单:构建提示,codenameone,Codenameone,这一问题涉及: 我在这里找到了一些文档: 在本文档中,有人写道,如果你的应用程序中没有包含CATEGORY_LEANBACK_LAUNCHER intent过滤器,则在电视设备上运行Google Play的用户将看不到该过滤器。 我尝试使用以下两个构建提示(包含源代码): 我注意到: : ... 第二个问题是,重复了两次:它是默认值,所以我不必指定它 当然,我不是AndroidManifest.xml的专家,这个问题是在再次提交应用程序进行审查之前,询问您对这些构建提示和生成的清单的意见。您
如果你的应用程序中没有包含CATEGORY_LEANBACK_LAUNCHER intent过滤器,则在电视设备上运行Google Play的用户将看不到该过滤器。
我尝试使用以下两个构建提示(包含源代码):
我注意到:
:
...
第二个问题是,
重复了两次:它是默认值,所以我不必指定它
当然,我不是AndroidManifest.xml的专家,这个问题是在再次提交应用程序进行审查之前,询问您对这些构建提示和生成的清单的意见。您不需要指定触摸屏,因为默认情况下包括触摸屏
android.xapplication
设计用于添加其他活动。我认为您应该使用android.xintent_filter
,而不是android.xaapplication
android.xpermissions=<uses-feature android:name="android.software.leanback" android:required="false" /><uses-feature android:name="android.hardware.touchscreen" android:required="false" />
android.xapplication=<intent-filter><action android:name="android.intent.action.MAIN" /><category android:name="android.intent.category.LEANBACK_LAUNCHER" /></intent-filter>
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="net.informaticalibera.apps.unialeph"
android:versionCode="100"
android:versionName="1.0"
xmlns:tools="http://schemas.android.com/tools"
android:minSdkVersion="15"
android:installLocation="auto">
<uses-sdk android:minSdkVersion="15" android:targetSdkVersion="27" />
<supports-screens android:smallScreens="true"
android:normalScreens="true"
android:largeScreens="true"
android:xlargeScreens="true"
android:anyDensity="true" />
<application android:label="UniAleph" android:icon="@drawable/icon" android:allowBackup="true" >
<provider
android:name="android.support.v4.content.FileProvider"
android:authorities="${applicationId}.provider"
android:exported="false"
android:grantUriPermissions="true">
<meta-data
android:name="android.support.FILE_PROVIDER_PATHS"
android:resource="@xml/file_paths">
</meta-data>
</provider><meta-data android:name="com.google.android.gms.version" android:value="@integer/google_play_services_version"/> <activity android:name="UniAlephStub"
android:theme="@style/CustomTheme"
android:configChanges="orientation|keyboardHidden|screenSize"
android:launchMode="singleTop"
android:label="UniAleph">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<intent-filter><action android:name="android.intent.action.MAIN" /><category android:name="android.intent.category.LEANBACK_LAUNCHER" /></intent-filter><receiver android:name="com.codename1.impl.android.LocalNotificationPublisher" ></receiver>
<service android:name="com.codename1.impl.android.BackgroundFetchHandler" android:exported="false" />
<activity android:name="com.codename1.impl.android.CodenameOneBackgroundFetchActivity" android:theme="@android:style/Theme.NoDisplay" />
<activity android:name="com.codename1.location.CodenameOneBackgroundLocationActivity" android:theme="@android:style/Theme.NoDisplay" />
<service android:name="com.codename1.location.BackgroundLocationHandler" android:exported="false" />
<service android:name="com.codename1.location.GeofenceHandler" android:exported="false" />
<service android:name="com.codename1.media.AudioService" android:exported="false" /> </application>
<uses-feature android:name="android.hardware.touchscreen" android:required="false" />
<uses-feature android:name="android.hardware.telephony" android:required="false" />
<uses-permission android:name="android.permission.INTERNET" android:required="false" />
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" android:required="false" />
<uses-feature android:name="android.software.leanback" android:required="false" /><uses-feature android:name="android.hardware.touchscreen" android:required="false" /></manifest>
<application
android:banner="@drawable/banner" >
...
<activity
android:name="com.example.android.MainActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity
android:name="com.example.android.TvActivity"
android:label="@string/app_name"
android:theme="@style/Theme.Leanback">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LEANBACK_LAUNCHER" />
</intent-filter>
</activity>
</application>