This commit is contained in:
陈君陶
2024-07-25 17:34:03 +08:00
parent 7cf2adaa37
commit 3c207244e6
101 changed files with 4708 additions and 267 deletions

View File

@ -15,6 +15,7 @@ import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_DOWNLOAD;
import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_GAME;
import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_GAME_COLLECTION_DETAIL;
import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_GAME_COLLECTION_SQUARE;
import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_INSTALL;
import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_INVOKE_ONLY;
import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_LIBAO;
import static com.gh.gamecenter.common.constant.EntranceConsts.HOST_QQ;
@ -56,6 +57,8 @@ import androidx.annotation.Nullable;
import com.gh.common.util.CheckLoginUtils;
import com.gh.common.util.DirectUtils;
import com.gh.common.util.EntranceUtils;
import com.gh.common.util.PackageInstaller;
import com.gh.download.DownloadManager;
import com.gh.gamecenter.common.base.activity.BaseActivity;
import com.gh.gamecenter.common.constant.Constants;
import com.gh.gamecenter.common.constant.EntranceConsts;
@ -77,6 +80,7 @@ import com.gh.vspace.shortcut.OnCreateShortcutResult;
import com.gh.vspace.shortcut.ShortcutManager;
import com.gh.vspace.shortcut.ShortcutPermissionTipsDialog;
import com.lightgame.config.CommonDebug;
import com.lightgame.download.DownloadEntity;
import com.lightgame.utils.Utils;
import com.muugi.shortcut.core.Executor;
@ -434,6 +438,13 @@ public class SkipActivity extends BaseActivity {
String restartGamePkg = uri.getQueryParameter(EntranceConsts.KEY_GAME_PKG);
VHelper.launch(this, restartGamePkg, false, true);
break;
case HOST_INSTALL:
String packageName = uri.getQueryParameter("package_name");
DownloadEntity downloadEntity = DownloadManager
.getInstance()
.getDownloadEntitySnapshotByPackageName(packageName);
PackageInstaller.install(this, downloadEntity);
break;
default:
EntranceUtils.jumpActivity(this, new Bundle()); // 跳转至首页
return;