DownloadEntry修改为DownloadEntity
This commit is contained in:
@ -19,7 +19,6 @@ import com.gh.common.util.DisplayUtils;
|
||||
import com.gh.common.util.DownloadItemUtils;
|
||||
import com.gh.common.util.GameViewUtils;
|
||||
import com.gh.common.util.ImageUtils;
|
||||
import com.gh.common.util.PlatformUtils;
|
||||
import com.gh.common.util.TimestampUtils;
|
||||
import com.gh.common.view.CardLinearLayout;
|
||||
import com.gh.download.DownloadManager;
|
||||
@ -156,8 +155,7 @@ public class PluginAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
|
||||
for (ApkEntity apkEntity : gameEntity.getApk()) {
|
||||
if (apkEntity.getPackageName().equals(key)) {
|
||||
GameEntity entity = gameEntity.clone();
|
||||
entity.setPluginPlatform(
|
||||
PlatformUtils.getInstance(context).getPlatformName(apkEntity.getPlatform()));
|
||||
entity.setPluggable(true);
|
||||
ArrayList<ApkEntity> apkList = new ArrayList<>();
|
||||
apkList.add(apkEntity);
|
||||
entity.setApk(apkList);
|
||||
@ -186,9 +184,9 @@ public class PluginAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
|
||||
private void initLocationMap() {
|
||||
for (int i = 0; i < pluginList.size(); i++) {
|
||||
GameEntity gameEntity = pluginList.get(i);
|
||||
locationMap.put(gameEntity.getName() + " - " + gameEntity.getPluginPlatform(), i);
|
||||
locationMap.put(gameEntity.getName() + " - " + gameEntity.getApk().get(0).getPlatform(), i);
|
||||
for (ApkEntity apkEntity : gameEntity.getApk()) {
|
||||
nameMap.put(apkEntity.getPackageName(), gameEntity.getName() + " - " + gameEntity.getPluginPlatform());
|
||||
nameMap.put(apkEntity.getPackageName(), gameEntity.getName() + " - " + gameEntity.getApk().get(0).getPlatform());
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -224,8 +222,8 @@ public class PluginAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
|
||||
viewHolder.home1_game_order.setVisibility(View.GONE);
|
||||
|
||||
ImageUtils.getInstance(context).display(entity.getIcon(), viewHolder.gameThumb);
|
||||
if (entity.getPluginPlatform() != null) {
|
||||
viewHolder.gameNameAndSize.setText(entity.getName() + " - " + entity.getPluginPlatform());
|
||||
if (entity.isPluggable()) {
|
||||
viewHolder.gameNameAndSize.setText(entity.getName() + " - " + entity.getApk().get(0).getPlatform());
|
||||
} else {
|
||||
viewHolder.gameNameAndSize.setText(entity.getName());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user