<manifest xmlns:android="http://schemas.android.com/apk/res/android"
          xmlns:tools="http://schemas.android.com/tools" package="com.github.shadowsocks"
          android:versionCode="142"
          android:versionName="3.0.0">

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

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

    <uses-sdk
            android:minSdkVersion="16"
            android:targetSdkVersion="24"/>

    <application
            android:allowBackup="true"
            android:name=".ShadowsocksApplication"
            android:hardwareAccelerated="true"
            android:icon="@drawable/ic_launcher"
            android:backupAgent=".ShadowsocksBackupAgent"
            android:label="@string/app_name"
            android:theme="@style/Theme.Material"
            android:banner="@drawable/ic_start_connected">

        <meta-data android:name="com.google.android.gms.version"
                   android:value="@integer/google_play_services_version"/>
        <meta-data android:name="com.google.android.backup.api_key"
                   android:value="AEdPqrEAAAAI_zVxZthz2HDuz9toTvkYvL0L5GA-OjeUIfBeXg"/>

        <activity
                android:name="com.google.android.gms.ads.AdActivity"
                android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>

        <activity
                android:name=".Shadowsocks"
                android:label="@string/app_name"
                android:launchMode="singleTask">
            <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>
            <intent-filter>
                <action android:name="android.service.quicksettings.action.QS_TILE" />
            </intent-filter>
        </activity>

        <activity
                android:name=".ShadowsocksRunnerActivity"
                android:theme="@android:style/Theme.NoDisplay"
                android:excludeFromRecents="true"
                android:launchMode="singleTask">
        </activity>

        <activity
                android:name=".ProfileManagerActivity"
                android:label="@string/profiles"
                android:parentActivityName=".Shadowsocks"
                android:excludeFromRecents="true"
                android:launchMode="singleTask">
            <intent-filter>
                <action android:name="com.github.shadowsocks.ProfileManagerActivity"/>
                <category android:name="android.intent.category.DEFAULT"/>
            </intent-filter>
            <intent-filter>
                <action android:name="android.intent.action.VIEW"/>
                <category android:name="android.intent.category.DEFAULT"/>
                <category android:name="android.intent.category.BROWSABLE"/>
                <data android:scheme="ss"/>
            </intent-filter>
            <intent-filter>
                <action android:name="android.nfc.action.NDEF_DISCOVERED"/>
                <category android:name="android.intent.category.DEFAULT"/>
                <data android:scheme="ss" />
            </intent-filter>
        </activity>

        <activity
                android:name=".ScannerActivity"
                android:label="@string/add_profile_methods_scan_qr_code"
                android:parentActivityName=".ProfileManagerActivity"
                android:excludeFromRecents="true"/>

        <activity
                android:name=".AppManager"
                android:label="@string/proxied_apps"
                android:parentActivityName=".Shadowsocks"
                android:excludeFromRecents="true"
                android:launchMode="singleTask"/>

        <activity android:name=".TaskerActivity"
                  android:icon="@drawable/ic_launcher">
            <intent-filter>
                <action android:name="com.twofortyfouram.locale.intent.action.EDIT_SETTING" />
            </intent-filter>
        </activity>

        <activity android:name=".ShadowsocksQuickSwitchActivity"
                  android:launchMode="singleInstance"
                  android:excludeFromRecents="true"
                  android:taskAffinity=""
                  android:theme="@style/PopupTheme.QuickSwitch">
            <intent-filter>
                <action android:name="com.github.shadowsocks.QUICK_SWITCH" />
                <category android:name="android.intent.category.DEFAULT"/>
            </intent-filter>
        </activity>

        <service
                android:name=".ShadowsocksRunnerService"
                android:exported="false">
        </service>

        <service
                android:name=".ShadowsocksNatService"
                android:process=":bg"
                android:exported="false">
        </service>

        <service
                android:name=".ShadowsocksVpnService"
                android:process=":bg"
                android:label="@string/app_name"
                android:permission="android.permission.BIND_VPN_SERVICE"
                android:exported="false">
            <intent-filter>
                <action android:name="android.net.VpnService"/>
            </intent-filter>
        </service>

        <service android:name=".ShadowsocksTileService" android:label="@string/quick_toggle"
                 android:process=":bg"
                 android:icon="@drawable/ic_start_connected"
                 android:permission="android.permission.BIND_QUICK_SETTINGS_TILE">
            <intent-filter>
                <action android:name="android.service.quicksettings.action.QS_TILE" />
            </intent-filter>
        </service>

        <receiver android:name=".BootReceiver" android:enabled="false">
            <intent-filter>
                <action android:name="android.intent.action.BOOT_COMPLETED"/>
            </intent-filter>
        </receiver>

        <receiver android:name=".TaskerReceiver" tools:ignore="ExportedReceiver">
            <intent-filter>
                <action android:name="com.twofortyfouram.locale.intent.action.FIRE_SETTING"/>
            </intent-filter>
        </receiver>
    </application>

</manifest>
