今天升级到 Android Studio 3.1.4 出现第一个错误
The option 'android.enableAapt2' is deprecated and should not be used anymore.
Use 'android.enableAapt2=true' to remove this warning.
It will be removed at the end of 2018..
然后我android.enableAapt2
按照它的建议将其更改为 true。
之后我有新的错误 AAPT2 错误
error: unknown element <intent-filter> found.
Message{kind=ERROR, text=error: unknown element <intent-filter> found., sources=[C:\FILE\Android Studio\UltraGreek\UltraGreekv.4.7\app\build\intermediates\manifests\full\debug\AndroidManifest.xml:37], original message=, tool name=Optional.of(AAPT)}
我在 app/srs/main/AndroidManifest.xml 中的清单是
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.ultragreek.ultragreek">
<uses-permission android:name="android.permission.INTERNET"/>
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE"/>
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE"/>
<application
android:allowBackup="true"
android:icon="@drawable/ultrasidelogo"
android:label="@string/app_name"
android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@style/AppTheme">
<activity
android:name=".MainActivity"
android:label="@string/app_name"
android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
<activity android:name=".ActivitySecond"/>
<activity android:name=".ActivityAbout"/>
<activity android:name=".WebViewer"/>
<intent-filter>
<action android:name="android.intent.action.SEND"/>
<category android:name="android.intent.category.DEFAULT"/>
<data android:mimeType="text/plain"/>
</intent-filter>
<activity
android:name=".ActivityStats"
android:label="Στατιστικά">
</activity>
</application>
</manifest>