summaryrefslogtreecommitdiff
path: root/android/hello_sdl_android/src/main/AndroidManifest.xml
blob: 6b577c5a25c2063bd0d778ab19dd1b8ae4963a59 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    package="com.sdl.hellosdlandroid">

    <uses-permission android:name="android.permission.BLUETOOTH" />
    <uses-permission android:name="android.permission.BLUETOOTH_CONNECT"
        tools:targetApi="31"/>
    <uses-permission android:name="android.permission.POST_NOTIFICATIONS"
        tools:targetApi="33"/>
    <uses-permission android:name="android.permission.INTERNET" />
    <!-- Required to check if WiFi is enabled -->
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <uses-permission android:name="android.permission.FOREGROUND_SERVICE" />

    <!-- Required to use the USB Accessory mode -->
    <uses-feature android:name="android.hardware.usb.accessory" />

    <!-- Required when targeting Android API 30+ -->
    <queries>
        <intent>
            <action android:name="com.smartdevicelink.router.service" />
        </intent>
        <intent>
            <action android:name="sdl.router.startservice" />
        </intent>
    </queries>

    <application
        android:allowBackup="false"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme"
        tools:ignore="DeepLinks">
        <activity
            android:name=".MainActivity"
            android:exported="true"
            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.smartdevicelink.transport.USBAccessoryAttachmentActivity"
            android:exported="true"
            android:launchMode="singleTop">
            <intent-filter>
                <action android:name="android.hardware.usb.action.USB_ACCESSORY_ATTACHED" />
            </intent-filter>

            <meta-data
                android:name="android.hardware.usb.action.USB_ACCESSORY_ATTACHED"
                android:resource="@xml/accessory_filter" />
        </activity>

        <service
            android:name="com.sdl.hellosdlandroid.SdlService"
            android:exported="true"
            android:foregroundServiceType="connectedDevice">
        </service>
        <service
            android:name=".SdlRouterService"
            android:exported="true"
            android:process="com.smartdevicelink.router"
            android:foregroundServiceType="connectedDevice">
            <intent-filter>
                <action android:name="com.smartdevicelink.router.service" />
            </intent-filter>
            <meta-data
                android:name="@string/sdl_router_service_version_name"
                android:value="@integer/sdl_router_service_version_value" />
        </service>

        <receiver
            android:name=".SdlReceiver"
            android:enabled="true"
            android:exported="true"
            tools:ignore="ExportedReceiver">
            <intent-filter>
                <action android:name="com.smartdevicelink.USB_ACCESSORY_ATTACHED" /> <!--For AOA -->
                <action android:name="android.bluetooth.device.action.ACL_CONNECTED" />
                <action android:name="sdl.router.startservice" />
            </intent-filter>
        </receiver>
        <activity
            android:name="com.smartdevicelink.managers.lockscreen.SDLLockScreenActivity"
            android:launchMode="singleTop" />
    </application>

</manifest>