小编Ale*_*vin的帖子

找不到Android 8.0-8.1(Oreo)API 26-27 ARM系统映像

对于AVD Manager,是否有适用于Android 8.0(Oreo)API 26和Android 8.1(Oreo)API 27 ARM系统映像(ARM,而不是x86 Intel)的任何地方?谢谢.

非官方?测试版?Α?任何?

android arm android-emulator android-8.0-oreo android-8.1-oreo

28
推荐指数
1
解决办法
6340
查看次数

找不到引用类java.lang.invoke.LambdaMetafactory

我在我的项目中包含了AndroidRate库

android {
    ...
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
    ...
}
dependencies {
    implementation fileTree(include: ['*.jar'], dir: 'libs')
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'com.android.support.test:runner:1.0.1'
    androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.1'
    implementation 'com.android.support:multidex:1.0.2'
    implementation 'com.android.support:support-annotations:27.0.2'
    implementation 'com.android.support:support-compat:27.0.2'
    implementation 'com.android.support:appcompat-v7:27.0.2'
    implementation 'com.google.android.gms:play-services-base:11.6.2'
    implementation 'com.google.android.gms:play-services-cast:11.6.2'
    implementation 'com.google.firebase:firebase-core:11.6.2'
    implementation 'com.google.firebase:firebase-crash:11.6.2'
    implementation 'com.google.firebase:firebase-appindexing:11.6.2'
    implementation 'com.vorlonsoft:androidrate:1.0.7'
    debugImplementation 'com.squareup.leakcanary:leakcanary-android:1.5.4'
    releaseImplementation 'com.squareup.leakcanary:leakcanary-android-no-op:1.5.4'
} 
Run Code Online (Sandbox Code Playgroud)

对于下面的代码,我得到:

警告:com.MyCompany.MyApp.MyAppClass:找不到引用的类java.lang.invoke.LambdaMetafactory

警告:有两个未解析的类或接口引用.

警告:处理任务java.io.IOException时发生异常:请先纠正上述警告.

错误:任务执行失败':mobile:transformClassesAndResourcesWithProguardForFree_Release'.

作业失败,请参阅日志了解详情

AppRate.with(this)
            .setStoreType(StoreType.GOOGLEPLAY)
            .setInstallDays((byte)1) // default 10, 0 means install day.
            .setLaunchTimes((byte)3) // default 10
            .setRemindInterval((byte)1) // default 1
            .setShowLaterButton(true) // default true …
Run Code Online (Sandbox Code Playgroud)

java lambda android java-8

12
推荐指数
1
解决办法
2820
查看次数

找不到Android 9.0(Pie)API 28 ARM系统映像

AVD Manager是否有适用于Android 9.0(Pie)API 28 ARM系统映像(ARM,而不是x86 Intel)?谢谢.

非官方?测试版?Α?任何?

sdk android arm android-emulator android-9.0-pie

12
推荐指数
0
解决办法
1708
查看次数

旧版Android API上的Apple Style AlertDialog

我正在研究AndroidRate库的Apple Style AlertDialog功能,无法解决 Android 9-10 API上的一些错误.

  1. 我无法在Android的9-10 API上删除AlertDialog边框

API 19: Android API 19上AndroidRate库的Apple Style AlertDialog API 10: Android API 10上AndroidRate库的Apple Style AlertDialog

  1. 我无法在Android的9-10 API上修复AlertDialog宽度

API 19: Android API 19上AndroidRate库的Apple Style AlertDialog API 10: Android API 10上AndroidRate库的Apple Style AlertDialog

我的style.xml:

<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ // Copyright 2018 Vorlonsoft LLC
  ~ //
  ~ // Licensed under The MIT License (MIT)
-->
<resources>

    <!-- Base Apple and Modern types Rate Dialog theme. -->
    <style name="RateDialogTransparentTheme">
        <item name="android:background">@color/rateDialogColorTransparent</item>
        <item name="android:backgroundDimEnabled">true</item>
        <item name="android:backgroundDimAmount">0.4</item>
        <item name="android:colorBackgroundCacheHint">@null</item>
        <item name="android:windowBackground">@color/rateDialogColorTransparent</item>
        <item name="android:windowContentOverlay">@null</item>
        <item name="android:windowFrame">@null</item>
        <item name="android:windowIsFloating">true</item>
        <item name="android:windowIsTranslucent">true</item>
        <item name="android:windowNoTitle">true</item>
        <item name="android:windowTitleStyle">@null</item>
    </style>

</resources> …
Run Code Online (Sandbox Code Playgroud)

android dialog android-alertdialog android-dialog

10
推荐指数
1
解决办法
390
查看次数

未解决的参考:JavaVersion.VERSION_1_8

如何解决以下错误?

android {
    ...
    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
    ...
}
Run Code Online (Sandbox Code Playgroud)

Android Studio->文件->项目结构->模块-> 未解决的参考:JavaVersion.VERSION_1_8

在此处输入图片说明

android gradle android-studio android-gradle-plugin

10
推荐指数
1
解决办法
1519
查看次数

找不到Android 7.1.1(Nougat)API 25 ARM系统映像

对于AVD Manager,有哪些Android 7.1.1(Nougat)API 25(25,而不是24)ARM系统映像(ARM,而不是x86 Intel)?谢谢

非官方?测试版?Α?任何?

sdk android arm android-emulator android-7.1-nougat

5
推荐指数
1
解决办法
1385
查看次数

onRenderProcessGone(WebView 视图,RenderProcessGoneDetail 详细信息)示例

下面我发布了我当前的onRenderProcessGone

  1. if (!detail.didCrash()) {}实例变量“view”保证为空时,重新初始化它是安全的。我应该自己重新初始化它还是系统会这样做?
  2. 您能否指定应用程序如何继续执行的逻辑示例?如何更优雅地处理崩溃?

        @TargetApi(Build.VERSION_CODES.O)
        @Override
        public boolean onRenderProcessGone(WebView view, RenderProcessGoneDetail detail) {
            // WebViewClient.onRenderProcessGone was added in O.
            if (Build.VERSION.SDK_INT < Build.VERSION_CODES.O) {
                return false;
            }
            super.onRenderProcessGone(view, detail);
    
            if (!detail.didCrash()) {
                // Renderer was killed because the system ran out of memory.
                // The app can recover gracefully by creating a new WebView instance
                // in the foreground.
                Log.e("MY_APP", "System killed the WebView rendering process " +
                        "to reclaim memory. Recreating...");
    
                if (view != …
    Run Code Online (Sandbox Code Playgroud)

android android-webview webviewclient android-8.0-oreo

5
推荐指数
1
解决办法
2956
查看次数

'ProductFlavor.resConfigs'有一个值'auto',它已经过时且尚未被替换

如何修复下面的警告?有没有"汽车"的替代品?

警告:DSL元素'ProductFlavor.resConfigs'的值为'auto',已过时且尚未替换.它将在2018年底删除

android {
    ...
    flavorDimensions "device", "paid", "market"
    productFlavors {
        phone {
            // Phone config version for the application
            resConfigs ("auto")
            dimension "device"
            matchingFallbacks = ['mobile']
        }
        ...     
    }
    ...
}
Run Code Online (Sandbox Code Playgroud)

android gradle build.gradle android-gradle-plugin android-studio-3.1

5
推荐指数
1
解决办法
1426
查看次数