<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Copyright (C) 2023 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.android.car.appgrid.test"
    xmlns:tools="http://schemas.android.com/tools">

    <!-- Permission to open recent tasks and to allow drag surface control to be transferred from DragEvent. -->
    <uses-permission android:name="android.permission.START_TASKS_FROM_RECENTS"/>
    <!-- System permission to query all installed packages -->
    <uses-permission android:name="android.permission.QUERY_ALL_PACKAGES"/>
    <!-- System permission to control media playback of the active session -->
    <uses-permission android:name="android.permission.MEDIA_CONTENT_CONTROL"/>
    <uses-permission android:name="android.permission.INTERACT_ACROSS_USERS_FULL"/>
    <uses-permission android:name="android.permission.FORCE_STOP_PACKAGES"/>
    <!-- System permission to query users on device -->
    <uses-permission android:name="android.permission.MANAGE_USERS"/>
    <uses-permission android:name="android.permission.CREATE_USERS"/>
    <!-- Needed to change component enabled state when user opens disabled apps. -->
    <uses-permission android:name="android.permission.CHANGE_COMPONENT_ENABLED_STATE"/>

    <application
        android:icon="@drawable/ic_launcher"
        android:label="@string/app_name"
        android:supportsRtl="true">

    <activity-alias
            android:name="com.android.car.appgrid.test.AppGridActivity"
            android:targetActivity="com.android.car.carlauncher.AppGridActivity"
            android:launchMode="singleInstance"
            android:exported="true"
            android:theme="@style/Theme.Launcher.AppGridActivity"
            android:excludeFromRecents="true">
            <meta-data android:name="distractionOptimized" android:value="true"/>
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity-alias>

    </application>

</manifest>
