gpt4 book ai didi

android - 找不到与给定名称匹配的资源 iys 将我标记为颜色?

转载 作者:行者123 更新时间:2023-11-29 23:49:25 24 4
gpt4 key购买 nike

大家好,我的项目中遇到了我的问题

Error:(3) Error retrieving parent for item: No resource found that matches the given name 'android:TextAppearance.Material.Widget.Button.Borderless.Colored'.

如果我点击跳转到资源

> <?xml version="1.0" encoding="utf-8"?> <resources>
> <style name="Base.TextAppearance.AppCompat.Widget.Button.Borderless.Colored"
> parent="android:TextAppearance.Material.Widget.Button.Borderless.Colored"/>
> <style name="Base.TextAppearance.AppCompat.Widget.Button.Colored" parent="android:TextAppearance.Material.Widget.Button.Colored"/>
> <style name="TextAppearance.AppCompat.Notification.Info.Media"/>
> <style name="TextAppearance.AppCompat.Notification.Media"/>
> <style name="TextAppearance.AppCompat.Notification.Time.Media"/>
> <style name="TextAppearance.AppCompat.Notification.Title.Media"/> </resources>

我的gradle文件是

build.gradle(Module:AppName) `

apply plugin: 'com.android.application'

android {
compileSdkVersion 'Google Inc.:Google APIs:24'
buildToolsVersion '24.0.0'
useLibrary 'org.apache.http.legacy'

defaultConfig {
applicationId "com.nileworx.flagsquiz"
minSdkVersion 11
targetSdkVersion 24
}

buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}

dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile project(':baseGameUtils')
compile 'com.android.support:support-v4:27.0.0'
compile 'com.google.android.gms:play-services:8.4.0'
compile 'com.google.android.gms:play-services-ads:8.4.0'
compile 'com.google.android.gms:play-services-identity:8.4.0'
compile 'com.google.android.gms:play-services-gcm:8.4.0'
}

build.gradle(模块:baseGameUtils)

apply plugin: 'com.android.library'

android {
compileSdkVersion 'Google Inc.:Google APIs:24'
buildToolsVersion '24.0.0'

defaultConfig {
minSdkVersion 11
targetSdkVersion 24
}

buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
} }

dependencies {
compile 'com.android.support:support-v4:27.1.1'
compile 'com.google.android.gms:play-services:+' }

顺便说一下它的游戏所以如果有人解决了请放上它

最佳答案

检查下图

enter image description here

android:TextAppearance.Material.Widget.Button.Borderless.Colored 需要 API 级别 24

您可以将所有内容都增加到 24 以遵循您的支持库,如下所示或更新到最新版本,这将解决问题,但请注意您的 minSDK 是 11,这意味着该样式不会应用于旧版本

apply plugin: 'com.android.application'

android {
compileSdkVersion 24
buildToolsVersion "24.0.0"
useLibrary 'org.apache.http.legacy'

defaultConfig {
applicationId "com.nileworx.flagsquiz"
minSdkVersion 11
targetSdkVersion 24
}

buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])

compile project(':baseGameUtils')

compile 'com.android.support:appcompat-v7:24.0.0'
compile 'com.android.support:support-v4:24.0.0'

compile 'com.google.android.gms:play-services:7.4.0'
compile 'com.google.android.gms:play-services-ads:7.4.0'
compile 'com.google.android.gms:play-services-identity:7.4.0'
compile 'com.google.android.gms:play-services-gcm:7.4.0'
}

关于android - 找不到与给定名称匹配的资源 iys 将我标记为颜色?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51065489/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com