这篇文章主要是对这个错误进行一个记录!

  • 首先是这个错误的发生场景:
    在Android的Project里面的res文件夹下有个专门放置xml资源的的drawable文件夹,这个文件夹不止一个,还有drawable-v24文件夹,做底部导航栏时,如果引用的drawable中的xml文件是位于drawable-v24文件夹下,就会出现这样的错误!所说的引用的xml文件就是此属性引用的xml文件:
app:DrawableTop="@drawable/main_tab_recommend_selector"
  • 这里是代码:
<?xml version="1.0" encoding="utf-8"?>"http://schemas.android.com/apk/res/android"    xmlns:app="http://schemas.android.com/apk/res-auto"    xmlns:tools="http://schemas.android.com/tools"    android:layout_width="match_parent"    android:layout_height="match_parent"    android:orientation="vertical"    tools:context="com.weibo.meishijie.mvp.view.activity.MainActivity">    "@+id/fragment"        android:layout_width="match_parent"        android:layout_height="match_parent"        android:layout_weight="1">    "@+id/bottom_navbar"        android:layout_width="match_parent"        android:layout_height="40dp"        android:orientation="horizontal">        <com.weibo.meishijie.mvp.view.widget.Nav_RadioButton            android:id="@+id/rb_recommend"            style="@style/bottom_bar_radiobutton_style"            android:layout_width="0dp"            android:layout_height="match_parent"            android:layout_weight="1"            android:checked="true"            android:text="推荐"            app:DrawableSize="30dp"            app:DrawableTop="@drawable/main_tab_recommend_selector" />        <com.weibo.meishijie.mvp.view.widget.Nav_RadioButton            android:id="@+id/rb_discovery"            style="@style/bottom_bar_radiobutton_style"            android:layout_width="0dp"            android:layout_height="match_parent"            android:layout_weight="1"            android:text="发现"            app:DrawableSize="30dp"            app:DrawableTop="@drawable/main_tab_discover_selector" />        <com.weibo.meishijie.mvp.view.widget.Nav_RadioButton            android:id="@+id/rb_store"            style="@style/bottom_bar_radiobutton_style"            android:layout_width="0dp"            android:layout_height="match_parent"            android:layout_weight="1"            android:text="商城"            app:DrawableSize="30dp"            app:DrawableTop="@drawable/main_tab_store_selector" />        <com.weibo.meishijie.mvp.view.widget.Nav_RadioButton            android:id="@+id/rb_topic"            style="@style/bottom_bar_radiobutton_style"            android:layout_width="0dp"            android:layout_height="match_parent"            android:layout_weight="1"            android:text="食话"            app:DrawableSize="30dp"            app:DrawableTop="@drawable/main_tab_topic_selector" />        <com.weibo.meishijie.mvp.view.widget.Nav_RadioButton            android:id="@+id/rb_mine"            style="@style/bottom_bar_radiobutton_style"            android:layout_width="0dp"            android:layout_height="match_parent"            android:layout_weight="1"            android:text="我的"            app:DrawableSize="30dp"            app:DrawableTop="@drawable/main_tab_mine_selector" />    

更多相关文章

  1. 一款常用的 Squid 日志分析工具
  2. GitHub 标星 8K+!一款开源替代 ls 的工具你值得拥有!
  3. RHEL 6 下 DHCP+TFTP+FTP+PXE+Kickstart 实现无人值守安装
  4. Linux 环境下实战 Rsync 备份工具及配置 rsync+inotify 实时同步
  5. Android关于arm64-v8a、armeabi-v7a、armeabi、X86的so文件兼容
  6. Android编程点滴(14) -- Android中资源文件夹res/raw和assets的
  7. Android(安卓)开发手记三
  8. android解析XML文件的三方法之Pull(读写)
  9. 如何修改原有的Android应用和添加应用

随机推荐

  1. Android换肤功能设计与实现(5)——网络加载
  2. 发布翻译的android英文教材《the busy co
  3. Android(安卓)动画系列之逐帧(Frame)动画详
  4. Android的几种布局方式
  5. PPS 推出 Android(安卓)版,用手機、平板電
  6. Android平板上开发应用的一点心得——精
  7. Android活跃用户总数达14亿人 平均每4个
  8. Android仿淘宝首页UI(附代源代码及示例图
  9. Android实习生面试记录-蘑菇街、网易等
  10. Android平板上开发应用的一点心得——精