This repository has been archived by the owner on Sep 15, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
5509fbb
commit c75a73b
Showing
269 changed files
with
46,762 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,6 @@ | ||
# Compiled class file | ||
*.class | ||
|
||
# Log file | ||
*.log | ||
|
||
# BlueJ files | ||
*.ctxt | ||
|
||
# Mobile Tools for Java (J2ME) | ||
.mtj.tmp/ | ||
|
||
# Package Files # | ||
*.jar | ||
*.war | ||
*.nar | ||
*.ear | ||
*.zip | ||
*.tar.gz | ||
*.rar | ||
|
||
# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml | ||
hs_err_pid* | ||
.gradle | ||
.idea | ||
build | ||
local.properties | ||
app/.cxx | ||
app/gm.jks |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,67 @@ | ||
apply plugin: 'com.android.application' | ||
|
||
android { | ||
signingConfigs { | ||
release { | ||
storeFile file('C:/Users/ASUS/Documents/GitHub/TiebaTS/app/gm.jks') | ||
storePassword 'gmgmgm' | ||
keyAlias 'key0' | ||
keyPassword '123456' | ||
} | ||
} | ||
compileSdkVersion 30 | ||
|
||
defaultConfig { | ||
applicationId 'gm.tieba.tabswitch' | ||
minSdkVersion 23 | ||
targetSdkVersion 30 | ||
versionCode 8 | ||
versionName "2.0" | ||
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner' | ||
multiDexEnabled false | ||
ndk{ | ||
abiFilters 'armeabi-v7a' | ||
} | ||
} | ||
buildTypes { | ||
debug { | ||
signingConfig signingConfigs.release | ||
} | ||
release { | ||
minifyEnabled true | ||
shrinkResources true | ||
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' | ||
signingConfig signingConfigs.release | ||
} | ||
} | ||
externalNativeBuild { | ||
buildToolsVersion '30.0.2' | ||
cmake { | ||
path file('/src/main/cpp/CMakeLists.txt') | ||
} | ||
} | ||
buildFeatures { | ||
viewBinding true | ||
} | ||
compileOptions { | ||
sourceCompatibility JavaVersion.VERSION_1_8 | ||
targetCompatibility JavaVersion.VERSION_1_8 | ||
} | ||
packagingOptions { | ||
exclude 'META-INF/DEPENDENCIES' | ||
exclude 'META-INF/NOTICE' | ||
exclude 'META-INF/LICENSE' | ||
exclude 'META-INF/LICENSE.txt' | ||
exclude 'META-INF/NOTICE.txt' | ||
} | ||
} | ||
|
||
dependencies { | ||
implementation 'androidx.appcompat:appcompat:1.2.0' | ||
implementation 'androidx.cardview:cardview:1.0.0' | ||
implementation 'androidx.recyclerview:recyclerview:1.1.0' | ||
compileOnly files('libs/XposedBridgeApi-89.jar') | ||
implementation files('libs/apksigner.jar') | ||
implementation group: 'com.squareup.okhttp3', name: 'okhttp', version: '5.0.0-alpha.2' | ||
implementation group: 'com.alibaba', name: 'fastjson', version: '1.2.75' | ||
} |
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
-repackageclasses "gm.tieba.tabswitch" | ||
-optimizations !code/simplification/arithmetic,!code/simplification/cast,!field/*,!class/merging/*,!code/allocation/variable | ||
-keepclassmembers class gm.tieba.tabswitch.ui.MainActivity {public static boolean isModuleActive();} | ||
-keep class gm.tieba.tabswitch.Hook |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<manifest xmlns:android="http://schemas.android.com/apk/res/android" | ||
xmlns:tools="http://schemas.android.com/tools" | ||
package="gm.tieba.tabswitch"> | ||
|
||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" /> | ||
<uses-permission android:name="android.permission.REQUEST_DELETE_PACKAGES" /> | ||
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" /> | ||
<uses-permission | ||
android:name="android.permission.QUERY_ALL_PACKAGES" | ||
tools:ignore="QueryAllPackagesPermission" /> | ||
|
||
<queries> | ||
<package android:name="io.github.lsposed.manager" /> | ||
<package android:name="com.baidu.tieba" /> | ||
<package android:name="com.eg.android.AlipayGphone" /> | ||
<package android:name="com.tencent.mm" /> | ||
<package android:name="bin.mt.plus" /> | ||
</queries> | ||
<application | ||
android:icon="@mipmap/ic_launcher" | ||
android:label="@string/app_name" | ||
android:roundIcon="@mipmap/ic_launcher_round" | ||
android:supportsRtl="true" | ||
android:theme="@style/Theme.TS"> | ||
<activity | ||
android:name="gm.tieba.tabswitch.ui.MainActivity" | ||
android:enabled="false" | ||
android:theme="@style/Theme.Launch"> | ||
<intent-filter> | ||
<action android:name="android.intent.action.MAIN" /> | ||
<category android:name="android.intent.category.LAUNCHER" /> | ||
</intent-filter> | ||
</activity> | ||
<activity-alias | ||
android:name=".MainActivityAlias" | ||
android:targetActivity=".ui.MainActivity"> | ||
<intent-filter> | ||
<action android:name="android.intent.action.MAIN" /> | ||
<category android:name="de.robv.android.xposed.category.MODULE_SETTINGS" /> | ||
</intent-filter> | ||
</activity-alias> | ||
|
||
<activity android:name="gm.tieba.tabswitch.ui.LicenseActivity" /> | ||
<activity android:name="gm.tieba.tabswitch.ui.DonationActivity" /> | ||
|
||
<provider | ||
android:name="androidx.core.content.FileProvider" | ||
android:authorities="gm.FileProvider" | ||
android:exported="false" | ||
android:grantUriPermissions="true"> | ||
<meta-data | ||
android:name="android.support.FILE_PROVIDER_PATHS" | ||
android:resource="@xml/file_paths" /> | ||
</provider> | ||
|
||
<meta-data | ||
android:name="xposedmodule" | ||
android:value="true" /> | ||
<meta-data | ||
android:name="xposeddescription" | ||
android:value="@string/description" /> | ||
<meta-data | ||
android:name="xposedminversion" | ||
android:value="53" /> | ||
<meta-data | ||
android:name="xposedscope" | ||
android:resource="@array/recommend_package" /> | ||
</application> | ||
</manifest> |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
gm.tieba.tabswitch.Hook |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
cmake_minimum_required(VERSION 3.10.2) | ||
project("TiebaTS") | ||
|
||
add_library(crust SHARED crust.cpp) | ||
|
||
|
||
find_library( # Sets the name of the path variable. | ||
log-lib | ||
|
||
# Specifies the name of the NDK library that | ||
# you want CMake to locate. | ||
log ) | ||
|
||
# Specifies libraries CMake should link to your target library. You | ||
# can link multiple libraries, such as libraries you define in this | ||
# build script, prebuilt third-party libraries, or system libraries. | ||
|
||
target_link_libraries( # Specifies the target library. | ||
crust | ||
|
||
# Links the target library to the log library | ||
# included in the NDK. | ||
${log-lib} ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
#include <android/log.h> | ||
#include <string> | ||
#include <cstring> | ||
#include <jni.h> | ||
|
||
#define LOGINFO(...) ((void)__android_log_print(ANDROID_LOG_INFO, "security", __VA_ARGS__)) | ||
#define LOGERROR(...) ((void)__android_log_print(ANDROID_LOG_ERROR, "security", __VA_ARGS__)) | ||
|
||
jint JNI_OnLoad(JavaVM *vm, void *reserved) { | ||
JNIEnv *env = nullptr; | ||
if (vm->GetEnv((void **) &env, JNI_VERSION_1_4) != JNI_OK) { | ||
return JNI_ERR; | ||
} | ||
return JNI_OK; | ||
} | ||
|
||
static jobject getApplication(JNIEnv *env) { | ||
jobject application = nullptr; | ||
jclass activity_thread_clz = env->FindClass("android/app/ActivityThread"); | ||
if (activity_thread_clz != nullptr) { | ||
jmethodID currentApplication = env->GetStaticMethodID( | ||
activity_thread_clz, "currentApplication", "()Landroid/app/Application;"); | ||
if (currentApplication != nullptr) { | ||
application = env->CallStaticObjectMethod(activity_thread_clz, currentApplication); | ||
} else { | ||
LOGERROR("Cannot find method: currentApplication() in ActivityThread."); | ||
} | ||
env->DeleteLocalRef(activity_thread_clz); | ||
} else { | ||
LOGERROR("Cannot find class: android.app.ActivityThread"); | ||
} | ||
return application; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// | ||
// Created by ASUS on 2021/2/11. | ||
// | ||
|
||
#ifndef 贴吧TS_CRUST_H | ||
#define 贴吧TS_CRUST_H | ||
|
||
|
||
class crust { | ||
|
||
}; | ||
|
||
|
||
#endif //贴吧TS_CRUST_H |
Oops, something went wrong.