コード例 #1
0
ファイル: PostFragment.java プロジェクト: Nodebuck/Pr0
  /** Loads the information about the post. This includes the tags and the comments. */
  private void loadPostDetails() {
    int delay = Sdk.isAtLeastKitKat() ? 500 : 100;

    feedService
        .loadPostDetails(feedItem.getId())
        .delay(delay, TimeUnit.MILLISECONDS, AndroidSchedulers.mainThread())
        .compose(bindUntilEvent(FragmentEvent.DESTROY_VIEW))
        .subscribe(this::onPostReceived, defaultOnError());
  }