<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.mobileer.oboetester">
    <uses-feature
        android:name="android.hardware.microphone"
        android:required="false" />
    <uses-feature
        android:name="android.hardware.audio.output"
        android:required="true" />
    <uses-feature
        android:name="android.hardware.touchscreen"
        android:required="false" />
    <uses-feature
        android:name="android.software.midi"
        android:required="false" />
    <uses-feature
        android:name="android.software.leanback"
        android:required="false" />

    <uses-permission android:name="android.permission.RECORD_AUDIO" />
    <uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
    <uses-permission android:name="android.permission.INTERNET" />
    <!-- This is needed for sharing test results. -->
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <uses-permission android:name="android.permission.READ_PHONE_STATE" />
    <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />

    <application
        android:allowBackup="false"
        android:fullBackupContent="false"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:supportsRtl="true"
        android:theme="@style/AppTheme"
        android:requestLegacyExternalStorage="true"
        android:banner="@mipmap/ic_launcher">
        <activity
            android:name=".MainActivity"
            android:label="@string/app_name"
            android:launchMode="singleTask"
            android:screenOrientation="portrait"
            android:exported="true">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
                <category android:name="android.intent.category.LEANBACK_LAUNCHER" />
            </intent-filter>
        </activity>
        <activity
            android:name=".TestOutputActivity"
            android:label="@string/title_activity_test_output"
            android:screenOrientation="portrait" />
        <activity
            android:name=".TestInputActivity"
            android:label="@string/title_activity_test_input"
            android:screenOrientation="portrait" />
        <activity
            android:name=".TapToToneActivity"
            android:label="@string/title_activity_output_latency"
            android:screenOrientation="portrait" />
        <activity
            android:name=".RecorderActivity"
            android:label="@string/title_activity_recorder"
            android:screenOrientation="portrait" />
        <activity
            android:name=".EchoActivity"
            android:label="@string/title_activity_echo"
            android:screenOrientation="portrait" />
        <activity
            android:name=".RoundTripLatencyActivity"
            android:label="@string/title_activity_rt_latency"
            android:screenOrientation="portrait" />
        <activity
            android:name=".ManualGlitchActivity"
            android:label="@string/title_activity_glitches"
            android:screenOrientation="portrait" />
        <activity
            android:name=".AutomatedGlitchActivity"
            android:label="@string/title_activity_auto_glitches"
            android:screenOrientation="portrait" />
        <activity
            android:name=".TestDisconnectActivity"
            android:label="@string/title_test_disconnect"
            android:screenOrientation="portrait" />
        <activity
            android:name=".DeviceReportActivity"
            android:label="@string/title_report_devices"
            android:screenOrientation="portrait" />
        <activity
            android:name=".TestDataPathsActivity"
            android:label="@string/title_data_paths"
            android:screenOrientation="portrait" />
        <activity
            android:name=".ExtraTestsActivity"
            android:exported="true"
            android:label="@string/title_extra_tests" />

        <activity
            android:name=".ExternalTapToToneActivity"
            android:label="@string/title_external_tap"
            android:exported="true" />
        <activity
            android:name=".TestPlugLatencyActivity"
            android:label="@string/title_plug_latency"
            android:exported="true" />
        <activity
            android:name=".TestErrorCallbackActivity"
            android:label="@string/title_error_callback"
            android:exported="true" />

        <service
            android:name=".MidiTapTester"
            android:permission="android.permission.BIND_MIDI_DEVICE_SERVICE"
            android:exported="true">
            <intent-filter>
                <action android:name="android.media.midi.MidiDeviceService" />
            </intent-filter>

            <meta-data
                android:name="android.media.midi.MidiDeviceService"
                android:resource="@xml/service_device_info" />
        </service>

        <provider
            android:name="android.support.v4.content.FileProvider"
            android:authorities="${applicationId}.provider"
            android:exported="false"
            android:grantUriPermissions="true">
            <meta-data
                android:name="android.support.FILE_PROVIDER_PATHS"
                android:resource="@xml/provider_paths" />
        </provider>
    </application>

</manifest>
