This commit is contained in:
wangcongtao
2020-09-04 17:13:35 +08:00
parent e1bdf00e19
commit 87bb6f0a36
14 changed files with 63 additions and 30 deletions

View File

@@ -174,12 +174,7 @@ public class AppsPresenter extends Presenter< AppsView > {
int page = 0;
int counter = 0;
for ( AppInfo appInfo : list ) {
if ( counter < AppsConst.TOTAL_SIZE_EACH_PAGE ) {
counter++;
} else {
page++;
counter = 0;
}
page = counter++ / AppsConst.TOTAL_SIZE_EACH_PAGE;
if ( !result.containsKey( page ) ) {
result.put( page, new ArrayList<>() );
}