We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
您好,看了您的博文 感觉非常受用,想跟您请教个问题,按照文档使用AndroidEventBus 发现 接收不到EventBus.getDefault().post("my_tag"); 传递过来的消息,不知如何解决,想跟您请教一二,发生这个事情问题会出现在哪?
MainActivity @OverRide protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.act_home); EventBus.getDefault().register(this); }
@Subscriber(tag = "my_tag",mode = ThreadMode.POST) private void updateUserWithTag() { ToastUtils.showShort(HomeActivity.this, "Passed parameters"); }
MyActivity //发送消息 EventBus.getDefault().post("my_tag");
看到请您能够及时回复我,谢谢~~
The text was updated successfully, but these errors were encountered:
@subscriber(tag = "my_tag",mode = ThreadMode.POST) private void updateUserWithTag() { ToastUtils.showShort(HomeActivity.this, "Passed parameters"); }
需要一个参数。
Sorry, something went wrong.
恩,非常感谢~我已解决,我原来以为只需要,不携带值传个tag 接收方就能做相应的事件
No branches or pull requests
您好,看了您的博文 感觉非常受用,想跟您请教个问题,按照文档使用AndroidEventBus 发现 接收不到EventBus.getDefault().post("my_tag"); 传递过来的消息,不知如何解决,想跟您请教一二,发生这个事情问题会出现在哪?
MainActivity
@OverRide
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.act_home);
EventBus.getDefault().register(this);
}
MyActivity
//发送消息
EventBus.getDefault().post("my_tag");
看到请您能够及时回复我,谢谢~~
The text was updated successfully, but these errors were encountered: