| | |
| | | import com.weikou.beibeivideo.BeibeiVideoAPI; |
| | | import com.weikou.beibeivideo.BeibeiVideoApplication; |
| | | import com.weikou.beibeivideo.ui.MyRetainViewFragment; |
| | | import com.weikou.beibeivideo.util.ad.AdUtil; |
| | | import com.weikou.beibeivideo.util.cache.DiskLruCacheManager; |
| | | import com.weikou.beibeivideo.util.downutil.StringUtils; |
| | | import com.yeshi.ec.library_baiducpu.R; |
| | |
| | | private synchronized void setData(String data) { |
| | | List<BaiDuCPUType> list = new Gson().fromJson(data, new TypeToken<List<BaiDuCPUType>>() { |
| | | }.getType()); |
| | | //删除萌萌哒 |
| | | if (list != null) |
| | | for (int i = 0; i < list.size(); i++) { |
| | | if (list.get(i).getName().contains("萌萌")) { |
| | | list.remove(i); |
| | | break; |
| | | } |
| | | } |
| | | //数据一致就不必更新 |
| | | if (itemList != null) { |
| | | String data1 = new Gson().toJson(itemList); |
| | |
| | | if (mlist.get(position).getId() == 1085) |
| | | return BaiDuShortVideosFragment.newInstance(mlist.get(position)); |
| | | else |
| | | return BaiDuCPUContentFragment.newInstance(mlist.get(position), mlist.get(position).getId() == 1085 ? BaiDuCPUContentFragment.VIEW_TYPE_SMALLVIDEO : BaiDuCPUContentFragment.VIEW_TYPE_VIDEO); |
| | | return BaiDuCPUContentFragment.newInstance(mlist.get(position), mlist.get(position).getId() == 1085 ? BaiDuCPUContentFragment.VIEW_TYPE_SMALLVIDEO : BaiDuCPUContentFragment.VIEW_TYPE_VIDEO, AdUtil.getAdPid(getContext(), AdUtil.POSITION_SPLASH) != null); |
| | | } |
| | | |
| | | @Override |