получить ошибку после добавления элегантной зависимости кнопки - PullRequest
0 голосов
/ 27 июня 2018

после добавления

implementation'com.cepheuen.elegant-number-button:lib:1.0.2'

получаю ошибку каждый раз, когда я добавляю эту зависимость

   Manifest merger failed : Attribute application@theme value=(@style/Theme.AppCompat.Light.NoActionBar) from AndroidManifest.xml:13:9-65
    is also present at [com.cepheuen.elegant-number-button:lib:1.0.2] AndroidManifest.xml:16:9-40 value=(@style/AppTheme).
    Suggestion: add 'tools:replace="android:theme"' to <application> element at AndroidManifest.xml:7:5-27:19 to override.

какая другая зависимость может использоваться для элегантной кнопки файл приложения модуля build.gradle

  apply plugin: 'com.android.application'

android {
    compileSdkVersion 27
    defaultConfig {
        applicationId "com.example.sharma.digimenu"
        minSdkVersion 21
        targetSdkVersion 27
        versionCode 1
        versionName "1.0"
        multiDexEnabled true
        testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
    }
    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
        }
    }
}

dependencies {
    implementation fileTree(dir: 'libs', include: ['*.jar'])
    implementation 'com.android.support:appcompat-v7:27.1.1'
    implementation 'com.android.support.constraint:constraint-layout:1.1.2'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.2'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'

    implementation 'com.google.firebase:firebase-core:16.0.1'
    implementation 'com.firebaseui:firebase-ui-auth:4.0.0'
    implementation 'com.firebaseui:firebase-ui-storage:4.0.0'
    implementation 'com.firebaseui:firebase-ui-database:4.0.0'

    implementation 'com.rengwuxian.materialedittext:library:2.1.4'
    implementation 'com.squareup.picasso:picasso:2.5.2'

    implementation'com.cepheuen.elegant-number-button:lib:1.0.2'
    implementation 'com.android.support:cardview-v7:27.1.1'
    implementation 'com.android.support:recyclerview-v7:27.1.1'
    implementation 'com.android.support:design:27.1.1'
}
apply plugin: 'com.google.gms.google-services'

Ответы [ 2 ]

0 голосов
/ 27 июня 2018

Выполните следующие изменения в Manifest.xml

<application
            android:allowBackup="true"
            android:icon="@mipmap/ic_launcher"
            android:label="@string/app_name"
            android:roundIcon="@mipmap/ic_launcher_round"
            android:supportsRtl="true"
            xmlns:tools="http://schemas.android.com/tools"
            tools:replace="android:theme"
            android:theme="@style/Theme.AppCompat.Light.NoActionBar">
            <activity android:name=".MainActivity">
                <intent-filter>
                    <action android:name="android.intent.action.MAIN" />

                    <category android:name="android.intent.category.LAUNCHER" />
                </intent-filter>
            </activity>
            <activity
                android:name=".Home"
                android:label="@string/title_activity_home"
                android:theme="@style/Theme.AppCompat.Light.NoActionBar" />
            <activity android:name=".FoodList"></activity>
        </application>
0 голосов
/ 27 июня 2018

Следуйте инструкциям, добавьте tools:replace="android:theme" к элементу <application>.

...