AndroidEventBus icon indicating copy to clipboard operation
AndroidEventBus copied to clipboard

poststick不起作用,原因是代码被注释了,请释放

Open yurenmatou opened this issue 7 years ago • 3 comments

image

yurenmatou avatar Aug 15 '18 04:08 yurenmatou

sticky事件是可以用的具体如下: 注册时使用 image

发送时使用 image

其余的和直接post用法一样,Sticky事件消耗完需要手动清除掉,不然会重复调用

image

shinobu59 avatar Oct 25 '18 06:10 shinobu59

 * 发送黏性消息事件,指定tag (每注册一次就能接受到一次,而且每次要清除栈否则会接受多个)
 * EventBus.getDefault().registerSticky(this);
 * EventBus.getDefault().removeStickyEvent(EventEntity.DiySetPreEntity.class, EventBusTags.DIY_SET_PREVIEW);

bigananas avatar Sep 03 '19 10:09 bigananas

sticky事件是可以用的具体如下: 注册时使用 image

发送时使用 image

其余的和直接post用法一样,Sticky事件消耗完需要手动清除掉,不然会重复调用

image

我是按照这样写了 但是只有第一次起作用,后面就失效了

is1988 avatar Mar 03 '23 03:03 is1988