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

    <!-- 通知权限 -->
    <uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
    <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" />
    <uses-permission android:name="android.permission.VIBRATE"/>

    
    <!-- 前台服务权限 -->
    <uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
    <uses-permission android:name="android.permission.FOREGROUND_SERVICE_SPECIAL_USE" />
    
    <!-- 网络权限（如果需要从网络获取通知内容） -->
    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    
    <!-- 锁屏监听权限 -->
    <uses-permission android:name="android.permission.WAKE_LOCK" />

    <application>
        <!-- WorkManager 初始化 -->
        <provider
            android:name="androidx.startup.InitializationProvider"
            android:authorities="${applicationId}.androidx-startup"
            android:exported="false">
            <meta-data
                android:name="androidx.work.WorkManagerInitializer"
                android:value="androidx.startup" />
        </provider>

        <!-- 通知删除监听器 -->
        <receiver
            android:name=".receiver.NotificationDeleteReceiver"
            android:exported="false">
            <intent-filter>
                <action android:name="com.remax.notification.ACTION_NOTIFICATION_DELETE" />
            </intent-filter>
        </receiver>

        <provider
            android:name=".provider.NotificationProvider"
            android:authorities="${applicationId}.notification.provider"
            android:exported="false" />
            
        <!-- FCM 消息处理服务 -->
        <service
            android:name=".service.FCMService"
            android:exported="false">
            <intent-filter>
                <action android:name="com.google.firebase.MESSAGING_EVENT" />
            </intent-filter>
        </service>
        
        <!-- 前台保活服务 -->
        <service
            android:name=".service.NotificationKeepAliveService"
            android:enabled="true"
            android:exported="false"
            android:foregroundServiceType="specialUse" />

    </application>

</manifest>