From cb48aaddae05025595844a230355eddcdceb5700 Mon Sep 17 00:00:00 2001 From: Milk <1871357815@qq.com> Date: Fri, 21 May 2021 11:58:58 +0800 Subject: [PATCH] go --- .gitignore | 2 +- .../top/niunaijun/blackbox/BlackBoxCore.java | 12 ------------ .../top/niunaijun/blackdex/MainActivity.java | 19 +++++++------------ 3 files changed, 8 insertions(+), 25 deletions(-) diff --git a/.gitignore b/.gitignore index 80af1ce..6f76fb3 100644 --- a/.gitignore +++ b/.gitignore @@ -87,4 +87,4 @@ lint/tmp/ *.DS_Store # git rm -r --cached . -# git add . \ No newline at end of file +# git add . \ No newline at end of file diff --git a/Bcore/src/main/java/top/niunaijun/blackbox/BlackBoxCore.java b/Bcore/src/main/java/top/niunaijun/blackbox/BlackBoxCore.java index c534712..af774e7 100644 --- a/Bcore/src/main/java/top/niunaijun/blackbox/BlackBoxCore.java +++ b/Bcore/src/main/java/top/niunaijun/blackbox/BlackBoxCore.java @@ -203,21 +203,9 @@ public class BlackBoxCore extends ClientConfiguration { return binder; } - /** - * Process type - */ private enum ProcessType { - /** - * Server process - */ Server, - /** - * Virtual app process - */ BAppClient, - /** - * Main process - */ Main, } diff --git a/app/src/main/java/top/niunaijun/blackdex/MainActivity.java b/app/src/main/java/top/niunaijun/blackdex/MainActivity.java index d6569cb..0f543e1 100644 --- a/app/src/main/java/top/niunaijun/blackdex/MainActivity.java +++ b/app/src/main/java/top/niunaijun/blackdex/MainActivity.java @@ -4,7 +4,6 @@ import androidx.appcompat.app.AppCompatActivity; import android.os.Bundle; import android.util.Log; -import android.view.View; import java.io.File; @@ -13,23 +12,19 @@ import top.niunaijun.blackbox.entity.pm.InstallResult; public class MainActivity extends AppCompatActivity { public static final String TAG = "MainActivity"; - public static final int USER_ID = 0; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); - findViewById(R.id.btn_click).setOnClickListener(new View.OnClickListener() { - @Override - public void onClick(View v) { - String hlx = "com.huluxia.gametools"; - boolean installed = BlackBoxCore.get().isInstalled(hlx); - if (!installed) { - InstallResult installResult = BlackBoxCore.get().installPackage(new File("/sdcard/huluxia.apk")); - Log.d(TAG, "onClick: " + installResult.toString()); - } - BlackBoxCore.get().launchApk(hlx); + findViewById(R.id.btn_click).setOnClickListener(v -> { + String hlx = "com.huluxia.gametools"; + boolean installed = BlackBoxCore.get().isInstalled(hlx); + if (!installed) { + InstallResult installResult = BlackBoxCore.get().installPackage(new File("/sdcard/huluxia.apk")); + Log.d(TAG, "onClick: " + installResult.toString()); } + BlackBoxCore.get().launchApk(hlx); }); } } \ No newline at end of file