Make it Simple
Make it Simple

Reputation: 1882

app launcher icon is not showing in home screen of android tv

When I install my app in my tv, I can run it and do everything but I do not know why app icon not showing on the home screen of the tv. Mainly its not displaying in 1080p Tv's

Here is my AndroidManifest:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.app.demo.tv">

    <uses-feature
        android:name="android.hardware.touchscreen"
        android:required="false" />
    <uses-feature
        android:name="android.software.leanback"
        android:required="true" />

    <permission
        android:name="com.app.demo.tv.ACCESS_VIDEO_DATA"
        android:protectionLevel="signature" />

    <uses-permission android:name="android.permission.INTERNET" />

    <application
        android:name=".Application"
        android:allowBackup="true"
        android:banner="@drawable/app_icon"
        android:icon="@drawable/app_icon"
        android:label="@string/app_name"
        android:theme="@style/AppTheme">



        <activity
            android:name=".HomeActivity"
            android:label="@string/app_name"
            android:theme="@style/HomeTheme">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <action android:name="android.intent.action.VIEW" />
                <category android:name="android.intent.category.LEANBACK_LAUNCHER" />
            </intent-filter>
        </activity>

        <activity
            android:name=".MainActivity"
            android:label="@string/app_name"
            android:theme="@style/LandingAndOtherTheme" />
    </application>

</manifest>

Upvotes: 4

Views: 6409

Answers (1)

Stanislav Bondar
Stanislav Bondar

Reputation: 6245

Just declare icons inside leanback launcher activity

<activity
 ...
 android:banner="@drawable/main_logo"
 android:icon="@mipmap/ic_launcher"
 android:logo="@mipmap/ic_launcher"
 ...
 >
  <intent-filter>
        <action android:name="android.intent.action.VIEW" />
        <action android:name="android.intent.action.MAIN" />
        <category android:name="android.intent.category.LEANBACK_LAUNCHER" />
  </intent-filter>
</activity>

Upvotes: 7

Related Questions