use of io.hefuyi.listener.event.FavourateSongEvent in project ListenerMusicPlayer by hefuyicoder.
the class ArtistFragment method subscribeFavourateSongEvent.
private void subscribeFavourateSongEvent() {
Subscription subscription = RxBus.getInstance().toObservable(FavourateSongEvent.class).subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread()).subscribe(new Action1<FavourateSongEvent>() {
@Override
public void call(FavourateSongEvent event) {
mPresenter.loadArtists(action);
}
}, new Action1<Throwable>() {
@Override
public void call(Throwable throwable) {
}
});
RxBus.getInstance().addSubscription(this, subscription);
}
Aggregations