Khaled Alramam
Khaled Alramam

Reputation: 47

My android app not compatible with android tv

I made an app that works on both mobile and TVs. It works fine when in debug or when i download its apk to the TV but when it was uploaded to play store it says that it's not compatible with TV, I mailed the support and they said it doesn't support TV though I did everything in the docs

Here is my manifests:

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

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

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

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

    <application
        android:allowBackup="true"
        android:banner="@drawable/banner"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:roundIcon="@mipmap/ic_launcher_round"
        android:supportsRtl="false"
        android:theme="@style/Theme.UniverseIPTV"
        android:usesCleartextTraffic="true">
        <activity android:name=".view.activity.tvactivity.SeriesDetailsForTv"/>
        <activity android:name=".view.activity.tvactivity.TvLiveOnTvActivity" />

        <service
            android:name=".FirebaseMS"
            android:exported="false">
            <intent-filter>
                <action android:name="com.google.firebase.MESSAGING_EVENT" />
            </intent-filter>
        </service>

        <activity
            android:name=".view.activity.MainActivity"
            android:configChanges="orientation"
            android:screenOrientation="portrait">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity android:name=".view.activity.SeriesDetailsActivity" />
        <activity android:name=".view.activity.MovieDetailsActivity" />
        <activity
            android:name=".view.activity.PlayVideoActivity"
            android:configChanges="orientation|keyboard|keyboardHidden|navigation"
            android:screenOrientation="landscape" />
        <activity
            android:name=".view.activity.tvactivity.TvMainActivity"
            android:configChanges="orientation"
            android:banner="@drawable/banner"
            android:screenOrientation="landscape">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LEANBACK_LAUNCHER" />
            </intent-filter>
        </activity>
    </application>

</manifest>

Upvotes: 1

Views: 1073

Answers (1)

Mayuri Khinvasara
Mayuri Khinvasara

Reputation: 1517

Your code doesn't seem to have a 'theme' set for launcher intent for your activity.

Also, If you do not include the CATEGORY_LEANBACK_LAUNCHER intent filter in your app, it is not visible to users running Google Play on TV devices. Also, if your app does not have this filter when you use developer tools to load it onto a TV device, the app does not appear in the TV user interface.


 <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>

Check the documentation here

Upvotes: 1

Related Questions