每个人都过得愉快。
我正在尝试在我的项目中使用我的项目v7库。
我已经从SDK管理器下载了它。但是,当我尝试编译我的项目时,它出现了一个问题。它告诉我已经定义了这些值,但我不知道这些值来自何处。
{project_path}\build\intermediates\res\merged\debug\values\values.xml
Error:(219) Attribute "titleTextStyle" has already been defined
Error:(219) Attribute "subtitleTextStyle" has already been defined
Error:(219) Attribute "divider" has already been defined
Error:(219) Attribute "background" has already been defined
Error:(219) Attribute "backgroundSplit" has already been defined
Error:(245) Attribute "dividerPadding" has already been defined
Error:(245) Attribute "textAllCaps" has already been defined
Error:(251) Attribute "navigationMode" has already been defined
Error:(259) Attribute "displayOptions" has already been defined
Error:(266) Attribute "title" has already been defined
Error:(266) Attribute "subtitle" has already been defined
Error:(266) Attribute "icon" has already been defined
Error:(266) Attribute "logo" has already been defined
Error:(266) Attribute "backgroundStacked" has already been defined
Error:(266) Attribute "customNavigationLayout" has already been defined
Error:(266) Attribute "homeLayout" has already been defined
Error:(266) Attribute "progressBarStyle" has already been defined
Error:(266) Attribute "indeterminateProgressStyle" has already been defined
Error:(266) Attribute "progressBarPadding" has already been defined
Error:(266) Attribute "itemPadding" has already been defined
Error:(269) Attribute "initialActivityCount" has already been defined
Error:(269) Attribute "expandActivityOverflowButtonDrawable" has already been defined
Error:(272) Attribute "itemTextAppearance" has already been defined
Error:(272) Attribute "itemBackground" has already been defined
Error:(272) Attribute "preserveIconSpacing" has already been defined
Error:(273) Attribute "iconifiedByDefault" has already been defined
Error:(273) Attribute "queryHint" has already been defined
Error:(292) Attribute "tabBackground" has already been defined
Error:(295) Attribute "windowActionBar" has already been defined
Error:(295) Attribute "windowNoTitle" has already been defined
Error:(295) Attribute "windowActionBarOverlay" has already been defined
Error:(295) Attribute "windowActionModeOverlay" has already been defined
Error:(295) Attribute "windowMinWidthMajor" has already been defined
Error:(295) Attribute "windowMinWidthMinor" has already been defined
...
这是我的build.gradle
apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion "23.0.1"
defaultConfig {
applicationId "com.app"
minSdkVersion 8
targetSdkVersion 23
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
}
}
}
dependencies {
compile project(':facebookSDK')
compile project(':libraryIndicators')
compile project(':library')
compile project(':librarySlide')
compile 'com.android.support:appcompat-v7:23.0.1'
compile 'com.android.support:design:23.0.1'
compile 'com.android.support:support-v4:23.0.1'
compile files('libs/libGoogleAnalyticsServices.jar')
}
我不知道我试图编译的其他项目是否存在问题。
答案 0 :(得分:0)
在我看来,第一个文本转储中列出的所有对象都已在代码中的其他位置定义。尝试从values.xml中注释这些项目,看看它是否可以编译。