xrecyclerview的loadmore的加载样式修改

查看了xrecyclerview的源码,loadmore的加载样式是LoadingMoreFooter实现的。LoadingMoreFooter中没有给出修改的方法。那么只有将recyclerview项目导为module,修改其源码。

  • 导入module到项目指定文件夹中:
    1.在项目的根目录下创建文件夹(例如:third)
    2.正常导入module,路径为根目录下
    3.在文件管理中将导入的module的文件夹拖到third文件夹下
    4.修改项目的setting.gradlesetting.gradle
    例如:
include ':third:xrecyclerview'
  • 导包完成之后运行报错:
Supertypes of the following classes cannot be resolved. Please make sure you have the required dependencies in the classpath:
    class com.loyo.customermodule.fragment.CustomerFragment, unresolved supertypes: com.jcodecraeer.xrecyclerview.XRecyclerView.LoadingListener

场景:我有一个公共模块,一个客户模块和订单模块(都导入公共模块),我公共模块需要对xrecyclerview进行二次封装,客户模块和订单模块使用。
解决办法:把library模块的依赖包implementation改为api,因为implementation依赖的包只能在本模块使用,api依赖的包可供其它模块使用
例如:
在公共模块的build.gradle中导入,使其他模块可以使用

    implementation project(':ThirdPartyLibrary:xrecyclerview')
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值