MrB*_*te' 6 android event-bus android-gradle-plugin
无法解析方法registerSticky(this)代替寄存器(this)
@Override
public void onStart() {
super.onStart();
EventBus.getDefault().register(this);
}
Run Code Online (Sandbox Code Playgroud)
我在Gradle中试过'org.greenrobot:eventbus:3.0.0'和'de.greenrobot:eventbus:3.0.0-beta1'.不知道为什么这种方法没有出现
Man*_* Le 11
它似乎registerSticky已被弃用和删除.我认为,你应该注册为正常事件,然后使用postSticky方法
@Subscribe(sticky = true, threadMode = ThreadMode.MAIN)
public void onEvent(MessageEvent event) {
//...
}
Run Code Online (Sandbox Code Playgroud)
请参阅:http://greenrobot.org/eventbus/documentation/configuration/sticky-events/
| 归档时间: |
|
| 查看次数: |
1535 次 |
| 最近记录: |