当试图在我的项目中使用最新的appcompat-v7支持库时,我得到以下错误:
/Users/greg/dev/mobile/android_project/app/build/intermediates/exploded-aar/com.android.support/appcompat-v7/21.0.0/res/values-v11/values.xml
Error:(36, 21) No resource found that matches the given name: attr 'android:actionModeShareDrawable'.
Error:(36, 21) No resource found that matches the given name: attr 'android:actionModeShareDrawable'.
Error:(36, 21) No resource found that matches the given name: attr 'android:actionModeShareDrawable'.
Error:(36, 21) No resource found that matches the given name: attr 'android:actionModeShareDrawable'.
我怎么解决这个问题?
在Android Studio中,我试图设置compileSdkVersion和targetSdkVersion为19。
我的解决方案是在构建的底部进行替换。Gradle,从这里:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:21.0.3'
}
旧版本的appcompat库:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:19.+'
}
在Android Studio中,我试图设置compileSdkVersion和targetSdkVersion为19。
我的解决方案是在构建的底部进行替换。Gradle,从这里:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:21.0.3'
}
旧版本的appcompat库:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:19.+'
}