The attribute "rippleColor" has already been defined

advertisements

I am trying to use MaterialDesignSupport lib and MaterialDesignLib (gitHub) in the same project

Gradle Dependcies:

dependencies {
    compile fileTree(include: ['*.jar'], dir: 'libs')
    compile 'com.github.navasmdc:MaterialDesign:1.5@aar'
    compile 'com.android.support:design:22.2.0'
    compile files('MaterialDesign/libs/nineoldandroids-2.4.0.jar') //that jar was missing from some reason
}

but i get Error:(1) Attribute "rippleColor" has already been defined. according to this answer the attr rippleColor is mentioned multiple times in the project and i should rename it but the file that contains the attr is under built folder and it regenerates every time so i can't rename it. Is there a way to rename built files or any way to solve this?


You have 2 different definitions of rippleColor in your app, so you'll not be able to compile it because the definitions are built probably in different libraries that you've used.

The only way I see to solve it is copying the code that you need from one of the libraries and avoid copying the rippleColor definition.