这些 Android logcat 警告是什么意思? [英] What do these Android logcat warnings mean?

查看:29
本文介绍了这些 Android logcat 警告是什么意思?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

它似乎不会影响我的应用程序中的任何内容......但.我是第一次使用 Android 支持库(迄今为止我的项目还没有使用支持库),但这是一个没有太多自定义方式的新项目.Activity 由 Android Studio 0.9.2 生成并实现了 Navigation Drawer.

It doesn't seem to impact anything in my app... yet. I'm using the Android support libraries for the first time (my projects to date have not used support libraries), but this is a new project without much in the way of customization yet. Activities were generated by Android Studio 0.9.2 and implement Navigation Drawer.

在运行 Android 4.4.2 的 Verizon Samsung Galaxy SIII 上运行.项目设置为 minSDK 为 15,目标 SDK 为 21.

Running this on a Verizon Samsung Galaxy SIII running Android 4.4.2. Project is set to minSDK of 15 and targeted SDK of 21.

11-21 10:31:18.204    7095-7095/com.myapp.debug I/dalvikvm﹕ Could not find method android.view.ViewGroup.onNestedScrollAccepted, referenced from method android.support.v7.internal.widget.ActionBarOverlayLayout.onNestedScrollAccepted
11-21 10:31:18.204    7095-7095/com.myapp.debug W/dalvikvm﹕ VFY: unable to resolve virtual method 11400: Landroid/view/ViewGroup;.onNestedScrollAccepted (Landroid/view/View;Landroid/view/View;I)V
11-21 10:31:18.204    7095-7095/com.myapp.debug D/dalvikvm﹕ VFY: replacing opcode 0x6f at 0x0000
11-21 10:31:18.204    7095-7095/com.myapp.debug I/dalvikvm﹕ Could not find method android.view.ViewGroup.onStopNestedScroll, referenced from method android.support.v7.internal.widget.ActionBarOverlayLayout.onStopNestedScroll
11-21 10:31:18.204    7095-7095/com.myapp.debug W/dalvikvm﹕ VFY: unable to resolve virtual method 11406: Landroid/view/ViewGroup;.onStopNestedScroll (Landroid/view/View;)V
11-21 10:31:18.204    7095-7095/com.myapp.debug D/dalvikvm﹕ VFY: replacing opcode 0x6f at 0x0000
11-21 10:31:18.204    7095-7095/com.myapp.debug I/dalvikvm﹕ Could not find method android.support.v7.internal.widget.ActionBarOverlayLayout.stopNestedScroll, referenced from method android.support.v7.internal.widget.ActionBarOverlayLayout.setHideOnContentScrollEnabled
11-21 10:31:18.204    7095-7095/com.myapp.debug W/dalvikvm﹕ VFY: unable to resolve virtual method 8977: Landroid/support/v7/internal/widget/ActionBarOverlayLayout;.stopNestedScroll ()V
11-21 10:31:18.204    7095-7095/com.myapp.debug D/dalvikvm﹕ VFY: replacing opcode 0x6e at 0x000e
11-21 10:31:18.234    7095-7095/com.myapp.debug I/dalvikvm﹕ Could not find method android.content.res.TypedArray.getChangingConfigurations, referenced from method android.support.v7.internal.widget.TintTypedArray.getChangingConfigurations
11-21 10:31:18.234    7095-7095/com.myapp.debug W/dalvikvm﹕ VFY: unable to resolve virtual method 368: Landroid/content/res/TypedArray;.getChangingConfigurations ()I
11-21 10:31:18.234    7095-7095/com.myapp.debug D/dalvikvm﹕ VFY: replacing opcode 0x6e at 0x0002
11-21 10:31:18.234    7095-7095/com.myapp.debug I/dalvikvm﹕ Could not find method android.content.res.TypedArray.getType, referenced from method android.support.v7.internal.widget.TintTypedArray.getType
11-21 10:31:18.234    7095-7095/com.myapp.debug W/dalvikvm﹕ VFY: unable to resolve virtual method 390: Landroid/content/res/TypedArray;.getType (I)I
11-21 10:31:18.234    7095-7095/com.myapp.debug D/dalvikvm﹕ VFY: replacing opcode 0x6e at 0x0002

如果我猜(我也是),我缺少 android.support.v7 需要的库.但我不知道在哪里可以找到它.

If I'm guessing (and I am), I'm missing a library that android.support.v7 requires. But I have no idea what or where to find it.

推荐答案

我想在@Monte Creasor 解释的基础上添加.我遇到了同样的问题并咨询了这个错误报告,它基本上说问题可能由 com.android.support:appcompat-v7:21.0.3 引起,这是使用 Android 新布局功能所需的主要依赖项.尝试回到 v7:20.0.0,这应该可以解决问题,就像对我和这个错误报告作者所做的那样.

I would like to add on top of what @Monte Creasor explained. I have had the same issue and consulted this bug report which basically says that the problem might be caused by com.android.support:appcompat-v7:21.0.3, on of the main dependencies required to use Android's new Layout capabilities. Try going back to the v7:20.0.0, this should solve the issue as it did for me and this bug report writer.

实际上,您需要更改的只是在应用程序 build.gradle 中的行:

Actually all you have to change is in the app build.gradle the line:

compile 'com.android.support:appcompat-v7:21.0.3' 或任何更高版本

编译'com.android.support:appcompat-v7:20.0.0'

这篇关于这些 Android logcat 警告是什么意思?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆