<?xml version="1.0" encoding="utf-8"?>
<!--
     Copyright (C) 2014 The Android Open Source Project

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->

<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.example.android.tvleanback"
    android:versionCode="1"
    android:versionName="1.1" >

    <uses-sdk
        android:minSdkVersion="19"
        android:targetSdkVersion="21" />

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

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

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

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

    <application
        android:allowBackup="false"
        android:icon="@drawable/videos_by_google_banner"
        android:label="@string/app_name"
        android:logo="@drawable/videos_by_google_banner"
        android:theme="@style/Theme.Example.Leanback" >
        <activity
            android:name=".ui.MainActivity"
            android:icon="@drawable/videos_by_google_banner"
            android:label="@string/app_name"
            android:logo="@drawable/videos_by_google_banner"
            android:screenOrientation="landscape" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

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

        </activity>

        <activity
            android:name=".ui.MovieDetailsActivity"
            android:exported="true">

            <!-- Receives the search request. -->
            <intent-filter>
                <action android:name="android.intent.action.SEARCH" />
                <!-- No category needed, because the Intent will specify this class component-->
           </intent-filter>

            <!-- Points to searchable meta data. -->
            <meta-data android:name="android.app.searchable"
                android:resource="@xml/searchable" />
        </activity>

        <activity android:name=".ui.PlaybackOverlayActivity"
            android:exported="true" />

        <activity
            android:name=".ui.VerticalGridActivity"
            android:exported="true"
            android:parentActivityName=".ui.MainActivity" />
        <activity
            android:name=".ui.SearchActivity"
            android:exported="true" />

        <activity android:name=".ui.BrowseErrorActivity"
            android:exported="true" />

        <!-- Provides search suggestions for keywords against video meta data. -->
        <provider android:name=".data.VideoContentProvider"
            android:authorities="com.example.android.tvleanback"
            android:exported="true" />

        <provider
            android:name=".recommendation.RecommendationBuilder$RecommendationBackgroundContentProvider"
            android:authorities="com.example.android.tvleanback.recommendation"
            android:exported="true" />

        <receiver
            android:name=".recommendation.BootupActivity"
            android:enabled="true"
            android:exported="false" >
            <intent-filter>
                <action android:name="android.intent.action.BOOT_COMPLETED" />
            </intent-filter>
        </receiver>

        <service
            android:name=".recommendation.UpdateRecommendationsService"
            android:enabled="true" />
    </application>

</manifest>