<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="chat.rocket.android">

    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.WAKE_LOCK" />
    <uses-permission android:name="android.permission.VIBRATE" />
    <uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />

    <permission
        android:name="${applicationId}.permission.C2D_MESSAGE"
        android:protectionLevel="signature" />

    <uses-permission android:name="${applicationId}.permission.C2D_MESSAGE" />

    <application
        android:name=".app.RocketChatApplication"
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:roundIcon="@mipmap/ic_launcher_round"
        android:supportsRtl="true">

        <activity
            android:name=".authentication.ui.AuthenticationActivity"
            android:configChanges="orientation"
            android:screenOrientation="portrait"
            android:theme="@style/AuthenticationTheme"
            android:windowSoftInputMode="adjustResize">
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.DEFAULT" />
                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>

        <activity
            android:name=".main.ui.MainActivity"
            android:windowSoftInputMode="adjustResize|stateAlwaysHidden"
            android:theme="@style/AppTheme" />

        <activity
            android:name=".webview.ui.WebViewActivity"
            android:windowSoftInputMode="adjustResize|stateAlwaysHidden"
            android:theme="@style/AppTheme" />

        <activity
            android:name=".webview.cas.ui.CasWebViewActivity"
            android:windowSoftInputMode="adjustResize|stateAlwaysHidden"
            android:theme="@style/AppTheme" />

        <activity
            android:name=".chatroom.ui.ChatRoomActivity"
            android:windowSoftInputMode="adjustResize|stateAlwaysHidden"
            android:theme="@style/AppTheme" />

        <activity
            android:name=".chatroom.ui.PinnedMessagesActivity"
            android:windowSoftInputMode="adjustResize|stateAlwaysHidden"
            android:theme="@style/AppTheme" />

        <activity
            android:name=".settings.password.ui.PasswordActivity"
            android:theme="@style/AppTheme" />

        <receiver
            android:name="com.google.android.gms.gcm.GcmReceiver"
            android:exported="true"
            android:permission="com.google.android.c2dm.permission.SEND">
            <intent-filter>
                <action android:name="com.google.android.c2dm.intent.RECEIVE" />
                <action android:name="com.google.android.c2dm.intent.REGISTRATION" />

                <category android:name="${applicationId}" />
            </intent-filter>
        </receiver>

        <service
            android:name=".push.FirebaseTokenService"
            android:exported="false">
            <intent-filter>
                <action android:name="com.google.firebase.INSTANCE_ID_EVENT" />
            </intent-filter>
        </service>

        <service
            android:name=".push.GcmListenerService"
            android:exported="false">
            <intent-filter>
                <action android:name="com.google.android.c2dm.intent.RECEIVE" />
            </intent-filter>
        </service>

        <meta-data
            android:name="io.fabric.ApiKey"
            android:value="12ac6e94f850aaffcdff52001af77ca415d06a43" />
    </application>

</manifest>