示例#1
0
 @Override
 public void onCheckedChanged(CompoundButton buttonView, boolean isChecked) {
   this.mIsFavoritesChecked = isChecked;
   if (mIsFavoritesChecked) {
     this.setSavedFilmsData();
     if (!sSAVED_FILMS.isEmpty()) {
       this.setSecondFragmentContent(sSAVED_FILMS.get(0));
     }
   } else {
     this.setDownloadedFilmsData();
   }
   if (mSwipeRefresh != null) {
     mSwipeRefresh.setEnabled(mIsFavoritesChecked);
   } else {
     UpdaterSyncAdapter.syncImmediately(this.getActivity());
   }
 }
示例#2
0
 @Override
 public void onRefresh() {
   mSwipeRefresh.setRefreshing(true);
   UpdaterSyncAdapter.syncImmediately(this.getActivity());
   mSwipeRefresh.setRefreshing(false);
 }