Android错误:找不到资源样式/Theme.AppInvite.Preview(又名myPackage:style / Theme.AppInvite.Preview)

时间:2018-08-24 05:25:11

标签: android android-studio android-gradle

在编译或运行项目时出错。我想计算出我旅行的距离。 我的Android Studio版本是 Android Studio 3.1.4

当我在 build.gradle(Model:app) 中添加以下库时,将发生此错误。

implementation 'com.google.android.gms:play-services-maps:12.0.1'
implementation 'com.google.android.gms:play-services:12.0.1'
implementation 'com.google.android.gms:play-services-location:12.0.1'

错误进入以下文件:

  

... \ app \ build \ intermediates \ manifests \ full \ debug \ AndroidManifest.xml

<?xml version="1.0" encoding="utf-8"?><manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="atjoin.measuredistance.app"
android:targetSandboxVersion="2"
android:versionCode="1"
android:versionName="1.0" >

<uses-sdk
    android:minSdkVersion="24"
    android:targetSdkVersion="28" />

<!-- Include required permissions for Google Maps API to run. -->
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
<uses-permission android:name="android.permission.INTERNET" />

<uses-feature
    android:glEsVersion="0x00020000"
    android:required="true" /> <!-- Optional permission for Analytics to run. -->
<uses-permission android:name="android.permission.WAKE_LOCK" /> <!-- Required by older versions of Google Play services to create GCM registration tokens -->
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />

<permission
    android:name="atjoin.measuredistance.app.permission.C2D_MESSAGE"
    android:protectionLevel="signature" />

<uses-permission android:name="atjoin.measuredistance.app.permission.C2D_MESSAGE" />

<application
    android:allowBackup="true"
    android:appComponentFactory="android.support.v4.app.CoreComponentFactory"
    android:debuggable="true"
    android:icon="@mipmap/ic_launcher"
    android:label="@string/app_name"
    android:roundIcon="@mipmap/ic_launcher_round"
    android:supportsRtl="true"
    android:testOnly="true"
    android:theme="@style/AppTheme" >
    <meta-data
        android:name="aia-compat-api-min-version"
        android:value="1" />

    <activity
        android:name="atjoin.measuredistance.MainActivity"
        android:label="@string/app_name"
        android:splitName="distance"
        android:theme="@style/AppTheme.NoActionBar" >
        <intent-filter android:order="1" >
            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.BROWSABLE" />
            <category android:name="android.intent.category.DEFAULT" />

            <data
                android:host="www.atjoin.in"
                android:pathPattern="/.*"
                android:scheme="https" />
        </intent-filter>
        <intent-filter>
            <action android:name="android.intent.action.MAIN" />

            <category android:name="android.intent.category.LAUNCHER" />
        </intent-filter>
    </activity>

    <receiver
        android:name="com.google.android.gms.analytics.AnalyticsReceiver"
        android:enabled="true"
        android:exported="false" >
    </receiver>

    <service
        android:name="com.google.android.gms.analytics.AnalyticsService"
        android:enabled="true"
        android:exported="false"
        android:splitName="distance" />
    <service
        android:name="com.google.android.gms.analytics.AnalyticsJobService"
        android:enabled="true"
        android:exported="false"
        android:permission="android.permission.BIND_JOB_SERVICE"
        android:splitName="distance" />

    <activity
        android:name="com.google.android.gms.appinvite.PreviewActivity"
        android:exported="true"
        android:splitName="distance"
        android:theme="@style/Theme.AppInvite.Preview" >
        <intent-filter>
            <action android:name="com.google.android.gms.appinvite.ACTION_PREVIEW" />

            <category android:name="android.intent.category.DEFAULT" />
        </intent-filter>
    </activity>
    <activity
        android:name="com.google.android.gms.auth.api.signin.internal.SignInHubActivity"
        android:excludeFromRecents="true"
        android:exported="false"
        android:splitName="distance"
        android:theme="@android:style/Theme.Translucent.NoTitleBar" />
    <!--
        Service handling Google Sign-In user revocation. For apps that do not integrate with
        Google Sign-In, this service will never be started.
    -->
    <service
        android:name="com.google.android.gms.auth.api.signin.RevocationBoundService"
        android:exported="true"
        android:permission="com.google.android.gms.auth.api.signin.permission.REVOCATION_NOTIFICATION"
        android:splitName="distance" />

    <receiver android:name="com.google.android.gms.cast.framework.media.MediaIntentReceiver" />

    <service
        android:name="com.google.android.gms.cast.framework.media.MediaNotificationService"
        android:splitName="distance" />
    <service
        android:name="com.google.android.gms.cast.framework.ReconnectionService"
        android:splitName="distance" />

    <activity
        android:name="com.google.firebase.auth.internal.FederatedSignInActivity"
        android:excludeFromRecents="true"
        android:exported="true"
        android:launchMode="singleInstance"
        android:permission="com.google.firebase.auth.api.gms.permission.LAUNCH_FEDERATED_SIGN_IN"
        android:splitName="distance"
        android:theme="@android:style/Theme.Translucent.NoTitleBar" />
    <activity
        android:name="com.google.android.gms.common.api.GoogleApiActivity"
        android:exported="false"
        android:splitName="distance"
        android:theme="@android:style/Theme.Translucent.NoTitleBar" /> <!-- Include the AdActivity and InAppPurchaseActivity configChanges and themes. -->
    <activity
        android:name="com.google.android.gms.ads.AdActivity"
        android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|uiMode|screenSize|smallestScreenSize"
        android:exported="false"
        android:splitName="distance"
        android:theme="@android:style/Theme.Translucent" />
    <!--
         FirebaseMessagingService performs security checks at runtime,
         no need for explicit permissions despite exported="true"
    -->
    <service
        android:name="com.google.firebase.messaging.FirebaseMessagingService"
        android:exported="true"
        android:splitName="distance" >
        <intent-filter android:priority="-500" >
            <action android:name="com.google.firebase.MESSAGING_EVENT" />
        </intent-filter>
    </service>
    <service
        android:name="com.google.android.gms.tagmanager.TagManagerService"
        android:enabled="true"
        android:exported="false"
        android:splitName="distance" />

    <activity
        android:name="com.google.android.gms.tagmanager.TagManagerPreviewActivity"
        android:exported="true"
        android:noHistory="true"
        android:splitName="distance" > <!-- optional, removes the previewActivity from the activity stack. -->
        <intent-filter>
            <data android:scheme="tagmanager.c.atjoin.measuredistance.app" />

            <action android:name="android.intent.action.VIEW" />

            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />
        </intent-filter>
    </activity>

    <receiver
        android:name="com.google.android.gms.measurement.AppMeasurementReceiver"
        android:enabled="true"
        android:exported="false" >
    </receiver>
    <receiver
        android:name="com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver"
        android:enabled="true"
        android:exported="true"
        android:permission="android.permission.INSTALL_PACKAGES" >
        <intent-filter>
            <action android:name="com.android.vending.INSTALL_REFERRER" />
        </intent-filter>
    </receiver>

    <service
        android:name="com.google.android.gms.measurement.AppMeasurementService"
        android:enabled="true"
        android:exported="false"
        android:splitName="distance" />
    <service
        android:name="com.google.android.gms.measurement.AppMeasurementJobService"
        android:enabled="true"
        android:exported="false"
        android:permission="android.permission.BIND_JOB_SERVICE"
        android:splitName="distance" />

    <receiver
        android:name="com.google.firebase.iid.FirebaseInstanceIdReceiver"
        android:exported="true"
        android:permission="com.google.android.c2dm.permission.SEND" >
        <intent-filter>
            <action android:name="com.google.android.c2dm.intent.RECEIVE" />

            <category android:name="atjoin.measuredistance.app" />
        </intent-filter>
    </receiver>
    <!--
         FirebaseInstanceIdService performs security checks at runtime,
         no need for explicit permissions despite exported="true"
    -->
    <service
        android:name="com.google.firebase.iid.FirebaseInstanceIdService"
        android:exported="true"
        android:splitName="distance" >
        <intent-filter android:priority="-500" >
            <action android:name="com.google.firebase.INSTANCE_ID_EVENT" />
        </intent-filter>
    </service>

    <provider
        android:name="com.google.firebase.provider.FirebaseInitProvider"
        android:authorities="atjoin.measuredistance.app.firebaseinitprovider"
        android:exported="false"
        android:initOrder="100"
        android:splitName="distance" />

    <meta-data
        android:name="com.google.android.gms.version"
        android:value="@integer/google_play_services_version" />
    <meta-data
        android:name="android.support.VERSION"
        android:value="26.1.0" />
</application>

请给我建议。 谢谢。

0 个答案:

没有答案