AndroidManifest.xml 4.61 KB
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="com.huawei.android.hms.agent">

    <!--HMS-SDK引导升级HMS功能,访问OTA服务器需要网络权限-->
    <uses-permission android:name="android.permission.INTERNET" />
    <!--HMS-SDK引导升级HMS功能,保存下载的升级包需要SD卡写权限-->
    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
    <!--检测网络状态-->
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
    <!--检测wifi状态-->
    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
    <!--获取用户手机的IMEI,用来唯一的标识设备。-->
    <uses-permission android:name="android.permission.READ_PHONE_STATE" />

    <application>
        <!-- 接入HMSSDK 需要注册的appid参数。value的值中“10492024”用实际申请的appid替换,来源于开发者联盟网站应用的权益详情。格式 android:value="appid=xxxxxx"-->
        <meta-data
            android:name="com.huawei.hms.client.appid"
            android:value="appid=100542863" />
        <!-- 接入HMSSDK 需要注册的provider,authorities 一定不能与其他应用一样,所以这边 com.hyphenate.chatuidemo 要替换上您应用的包名-->
        <provider
            android:name="com.huawei.hms.update.provider.UpdateProvider"
            android:authorities="com.chudiangameplay.android.hms.update.provider"
            android:exported="false"
            android:grantUriPermissions="true" />
        <!-- 接入HMSSDK 需要注册的provider,authorities 一定不能与其他应用一样,所以这边 com.hyphenate.chatuidemo 要替换上您应用的包名-->
        <provider
            android:name="com.huawei.updatesdk.fileprovider.UpdateSdkFileProvider"
            android:authorities="com.chudiangameplay.android.updateSdk.fileProvider"
            android:exported="false"
            android:grantUriPermissions="true"/>
        <!-- 使用 HMSAgent 代码接入HMSSDK 需要注册的activity-->
        <activity
            android:name="com.huawei.android.hms.agent.common.HMSAgentActivity"
            android:configChanges="orientation|locale|screenSize|layoutDirection|fontScale"
            android:excludeFromRecents="true"
            android:exported="false"
            android:hardwareAccelerated="true"
            android:theme="@android:style/Theme.Translucent">
            <meta-data
                android:name="hwc-theme"
                android:value="androidhwext:style/Theme.Emui.Translucent" />
        </activity>
        <!-- 接入HMSSDK 需要注册的activity-->
        <activity
            android:name="com.huawei.hms.activity.BridgeActivity"
            android:configChanges="orientation|locale|screenSize|layoutDirection|fontScale"
            android:excludeFromRecents="true"
            android:exported="false"
            android:hardwareAccelerated="true"
            android:theme="@android:style/Theme.Translucent">
            <meta-data
                android:name="hwc-theme"
                android:value="androidhwext:style/Theme.Emui.Translucent" />
        </activity>
        <!-- 接入HMSSDK 需要注册的activity-->
        <activity
            android:name="com.huawei.updatesdk.service.otaupdate.AppUpdateActivity"
            android:configChanges="orientation|screenSize"
            android:exported="false"
            android:theme="@style/upsdkDlDialog">
            <meta-data
                android:name="hwc-theme"
                android:value="androidhwext:style/Theme.Emui.Translucent.NoTitleBar" />
        </activity>
        <!-- 接入HMSSDK 需要注册的activity-->
        <activity
            android:name="com.huawei.updatesdk.support.pm.PackageInstallerActivity"
            android:configChanges="orientation|keyboardHidden|screenSize"
            android:exported="false"
            android:theme="@style/upsdkDlDialog">
            <meta-data
                android:name="hwc-theme"
                android:value="androidhwext:style/Theme.Emui.Translucent" />
        </activity>
        <!-- 接入HMSSDK PUSH模块需要注册 :接收通道发来的通知栏消息-->
        <receiver android:name="com.huawei.hms.support.api.push.PushEventReceiver">
            <intent-filter>
                <action android:name="com.huawei.intent.action.PUSH" />
            </intent-filter>
        </receiver>
        <!-- 接入HMSSDK 需要注册的应用下载服务-->
        <service
            android:name="com.huawei.updatesdk.service.deamon.download.DownloadService"
            android:exported="false" />
    </application>

</manifest>