About

<#TEMPLATE_INCLUDE_NINEPAGE_ABOUTME#>
  • Mar

    27

    安卓开发时 BaiDu 与 Admob 广告平台添加的 activity 配置

    • 0 Comments
    • Miscellaneous
    • 发布:古树悬叶
    • 引用:0
    • 浏览:
    <android>
            <manifestAdditions><![CDATA[
                <manifest android:installLocation="auto">

                    <!-- 防止APP打开时移动设备自动进入休眠状态 -->
                    <uses-permission android:name="android.permission.WAKE_LOCK" />
                    <uses-permission android:name="android.permission.WRITE_SETTINGS" />

                    <!-- 百度与AdMob所需权限 -->
                    <uses-permission android:name="android.permission.INTERNET"/>
                    <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>
                    <uses-permission android:name="android.permission.ACCESS_FINE_LOCATION"/>
                    <uses-permission android:name="android.permission.READ_PHONE_STATE"/>
                    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
                    <uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
                    <uses-permission android:name="android.permission.ACCESS_COARSE_LOCATION"/>

                     <application>
                            <meta-data     android:name="com.google.android.gms.version"
                                           android:value="@integer/google_play_services_version" />
                                 <activity     android:name="com.google.android.gms.ads.AdActivity" 
                                               android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"/>

                                 <activity android:name="com.baidu.mobads.AppActivity" android:configChanges="keyboard|keyboardHidden|orientation"/>
                     </application>

                </manifest>
            ]]></manifestAdditions>
        </android>