zoukankan      html  css  js  c++  java
  • android 错误解决


    转自:https://blog.csdn.net/gbstyle/article/details/82926358 

    错误1:

    com.android.ddmlib.AdbCommandRejectedException: device unauthorized.
    This adb server's $ADB_VENDOR_KEYS is not set
    Try 'adb kill-server' if that seems wrong.
    Otherwise check for a confirmation dialog on your device.
    Error while Installing APK

    解决方案:

    手机-设置-应用程序-开发-usb调试打开再关闭一次

    错误2:

    关于FrameLayout的介绍是:FrameLayout内的子View会被绘制在一个栈中,最后添加的组件会被添加在最上面。按照这样的说法,应该是ImageView会覆盖在Button上面的。但是实际的效果却是这个样子的:

    按钮显示在了FrameLayout的顶部。

    原因分析:

    按钮在Lollipop以及之后的版本,默认都有一个高度,这个也就是造成为什么在FrameLayout中绘制的时候会被绘制在最上层。

    解决方法一:

    设置Button的stateListAnimator属性

    android:stateListAnimator="@null"

    不过这样做的话,按钮的阴影效果也会不见

    解决方法二:

    设置其他View的elevation属性

    <ImageView
    android:layout_width="wrap_content"
    android:layout_height="wrap_content"
    android:src="@mipmap/ic_launcher"
    android:elevation="2dp"

    错误3:

    转自https://blog.csdn.net/crheh/article/details/78358004

    android studio 运行出现“The activity must be exported or contain an intent-filter

    在studio界面的run下面有一个框

    这里写图片描述

    在里面选app文件夹 
    这里写图片描述 
    之后再运行就好了

  • 相关阅读:
    WSGI原理
    主从数据库
    mysql高级
    记录
    获取当前时间
    sql注入和防sql注入
    python操作MySQL
    修改Windows10 命令终端cmd的编码为UTF-8
    MySQL查询
    MySQL数据库操作
  • 原文地址:https://www.cnblogs.com/xuqp/p/11057379.html
Copyright © 2011-2022 走看看