我在 appcompat_v7 和 FloatingButtonAction 中有两个属性

I have two attr in appcompat_v7 and FloatingButtonAction

我的项目包含这两个库,但由于某种原因,当我想在我的设备上 运行 时出现错误:

错误如下:

workspace_desarrollo\Librerias\FloatingActionButton\res\values\attrs.xml:6: error: Attribute "color" has already been defined

查看这两个库,发现都定义了。我所做的是重命名 FAB 库,内容如下:

<attr name="colortem" format="color"/>

一切正常,但是当你运行 APP 时,按钮显示为白色背景。有 3 个按钮,使用并放置三个白色背景。

以前我没有这个问题,但我不得不更换 PC 并且当您导入新的工作区项目时开始约会这个错误。

appcompat_v7 这在 : target=android-21

FloatingActionButton 位于: target=android-19 android.library=true android.library.reference.1=../nineoldandroids

我的项目在: target=android-21 android.library.reference.1=../../Librerias/FloatingActionButton android.library.reference.2=../../Librerias/appcompat android.library.reference.3=../../Librerias/google-play-services_lib

希望你能帮帮我。

谢谢

PD : 我正在考虑开始开发 android studio ,但我并不完全相信

删除colortem属性定义,将使用另一个。否则,您必须将 FAB 库中的所有 R.attr.color 引用也更改为 R.attr.colortem