摘要: 【爱迪的懂】接上一篇内容,本篇学习 EventBus 的粘性事件。 一. 流程 1. 构造信息发送类2. 发布消息(MainActivity) EventBus.getDefault().postSticky()3. 接收消息(SecondActivity)4. 注册(SecondActivity) 阅读全文
posted @ 2020-04-23 17:14 爱迪的懂 阅读(713) 评论(0) 推荐(0)
摘要: 【爱迪的懂】 本篇博客是关于EventBus 的基本使用步骤,一起来学习吧! 一. 整体流程 1. 添加 EventBus依赖 : implementation 'org.greenrobot:eventbus:3.1.1' 2. 注册: EventBus.getDefault().register 阅读全文
posted @ 2020-04-23 16:10 爱迪的懂 阅读(436) 评论(0) 推荐(0)