private void selectTopLeagues() { List<String> filterLeagueIdList2 = new ArrayList<String>(); for (League league : topLeagues) { filterLeagueIdList2.add(league.getLeagueId()); } Set<String> selectedSet2 = new HashSet<String>(); selectedSet2.addAll(filterLeagueIdList2); leagueManager.setLeagueList(topLeagues); leagueManager.setFilterLeagueSet(selectedSet2); oddsManager.setFilterLeagueIdList(filterLeagueIdList2); }
private void reloadListDataAndView() { if (firstLoad) { // 默认一级赛事 List<String> filterLeagueIdList = new ArrayList<String>(); for (League league : topLeagues) { filterLeagueIdList.add(league.getLeagueId()); } oddsManager.setFilterLeagueIdList(filterLeagueIdList); // 设置筛选的联赛 leagueManager.setLeagueList(topLeagues); Set<String> filterSet = new HashSet<String>(); filterSet.addAll(filterLeagueIdList); leagueManager.setFilterLeagueSet(filterSet); firstLoad = false; } matchOddsMap = oddsManager.filterOddsByOddsType(companyManager.getOddsType()); updateMatchOddsMap(); updateNoOddsTextView(); adapter.notifyDataSetChanged(); }