zoukankan      html  css  js  c++  java
  • RecyclerView只有一行

     
    RecyclerView只有一行
    方法1:
    将RecyclerView放在父容器RelativeLayout中,并设置RelativeLayout属性
    android:descendantFocusability="blocksDescendants"
    但是这样又会让RecyclerView的滑动与ScrollView冲突了,没有惯性,其实我并不需要RecyclerView的滑动属性,RecyclerView只是用来显示数据的,所以把RecyclerView的滑动属性禁用掉就可以了,
    代码里设置
    recycleview.setNestedScrollingEnabled(false);
    或者:
    android:nestedScrollingEnabled="false"
  • 相关阅读:
    RabbitMQ
    Java 多线程
    Java 多线程
    Java 多线程
    Java 多线程
    Springboot
    SpringBoot
    SpringCloud Config
    Financial
    Hystrix
  • 原文地址:https://www.cnblogs.com/mamamia/p/11226024.html
Copyright © 2011-2022 走看看