diff --git a/app/src/main/java/com/lt2333/simplicitytools/activity/SettingsActivity.kt b/app/src/main/java/com/lt2333/simplicitytools/activity/SettingsActivity.kt index 4175661f..acf451be 100644 --- a/app/src/main/java/com/lt2333/simplicitytools/activity/SettingsActivity.kt +++ b/app/src/main/java/com/lt2333/simplicitytools/activity/SettingsActivity.kt @@ -347,84 +347,6 @@ class SettingsActivity : MIUIActivity() { return getString(R.string.menu) } - fun aboutItems(): ArrayList { - return ArrayList().apply { - add(AuthorV(authorHead = getDrawable(R.drawable.lt)!!,authorName = "乌堆小透明",authorTips = "开发者",onClick = { - try { - startActivity( - Intent( - Intent.ACTION_VIEW, - Uri.parse("coolmarket://u/883441") - ) - ) - Toast.makeText(activity, "乌堆小透明:靓仔,点个关注吧!", Toast.LENGTH_SHORT) - .show() - } catch (e: Exception) { - Toast.makeText(activity, "本机未安装酷安应用", Toast.LENGTH_SHORT).show() - val uri = Uri.parse("http://www.coolapk.com/u/883441") - val intent = Intent(Intent.ACTION_VIEW, uri) - startActivity(intent) - } - })) - add( - TextSummaryArrowV( - TextSummaryV( - textId = R.string.opensource, - tipsId = R.string.github_url, - onClickListener = { - try { - val uri = - Uri.parse("https://github.com/LittleTurtle2333/Simplicity_Tools_Xposed") - val intent = Intent(Intent.ACTION_VIEW, uri) - startActivity(intent) - } catch (e: Exception) { - Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() - } - }) - ) - ) - add( - TextSummaryArrowV( - TextSummaryV( - textId = R.string.issues, - tipsId = R.string.issues_url, - onClickListener = { - try { - val uri = - Uri.parse("https://github.com/LittleTurtle2333/Simplicity_Tools_Xposed/issues") - val intent = Intent(Intent.ACTION_VIEW, uri) - startActivity(intent) - } catch (e: Exception) { - Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() - } - }) - ) - ) - add( - TextSummaryArrowV( - TextSummaryV( - textId = R.string.verison, - tips = "${BuildConfig.VERSION_NAME}(${BuildConfig.BUILD_TYPE})", - onClickListener = { - try { - val uri = - Uri.parse("https://github.com/Xposed-Modules-Repo/com.lt2333.simplicitytools/releases") - val intent = Intent(Intent.ACTION_VIEW, uri) - startActivity(intent) - } catch (e: Exception) { - Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() - } - } - ) - ) - ) - } - } - - fun aboutName(): String { - return getString(R.string.about_module) - } - override fun menuItems(): ArrayList { return ArrayList().apply { add( @@ -475,6 +397,128 @@ class SettingsActivity : MIUIActivity() { } } + fun aboutName(): String { + return getString(R.string.about_module) + } + + fun aboutItems(): ArrayList { + return ArrayList().apply { + add( + AuthorV( + authorHead = getDrawable(R.drawable.lt)!!, + authorName = "乌堆小透明", + authorTips = "开发者", + onClick = { + try { + startActivity( + Intent( + Intent.ACTION_VIEW, + Uri.parse("coolmarket://u/883441") + ) + ) + Toast.makeText(activity, "乌堆小透明:靓仔,点个关注吧!", Toast.LENGTH_SHORT) + .show() + } catch (e: Exception) { + Toast.makeText(activity, "本机未安装酷安应用", Toast.LENGTH_SHORT).show() + val uri = Uri.parse("http://www.coolapk.com/u/883441") + val intent = Intent(Intent.ACTION_VIEW, uri) + startActivity(intent) + } + }) + ) + add( + TitleTextV(text = getString(R.string.thank_list)) + ) + add( + TextSummaryArrowV( + TextSummaryV( + textId = R.string.contributor_list, + onClickListener = { + try { + val uri = + Uri.parse("https://github.com/LittleTurtle2333/SimplicityTools/graphs/contributors") + val intent = Intent(Intent.ACTION_VIEW, uri) + startActivity(intent) + } catch (e: Exception) { + Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() + } + }) + ) + ) + add( + TextSummaryArrowV( + TextSummaryV( + textId = R.string.third_party_open_source_statement, + onClickListener = { + try { + val uri = + Uri.parse("https://github.com/LittleTurtle2333/SimplicityTools/tree/main/doc/ThirdPartyOpenSourceStatement.md") + val intent = Intent(Intent.ACTION_VIEW, uri) + startActivity(intent) + } catch (e: Exception) { + Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() + } + }) + ) + ) + add( + TitleTextV(text = getString(R.string.other)) + ) + add( + TextSummaryArrowV( + TextSummaryV( + textId = R.string.opensource, + tipsId = R.string.github_url, + onClickListener = { + try { + val uri = + Uri.parse("https://github.com/LittleTurtle2333/SimplicityTools") + val intent = Intent(Intent.ACTION_VIEW, uri) + startActivity(intent) + } catch (e: Exception) { + Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() + } + }) + ) + ) + add( + TextSummaryArrowV( + TextSummaryV( + textId = R.string.issues, + tipsId = R.string.issues_url, + onClickListener = { + try { + val uri = + Uri.parse("https://github.com/LittleTurtle2333/SimplicityTools/issues") + val intent = Intent(Intent.ACTION_VIEW, uri) + startActivity(intent) + } catch (e: Exception) { + Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() + } + }) + ) + ) + add( + TextSummaryArrowV( + TextSummaryV( + textId = R.string.verison, + tips = "${BuildConfig.VERSION_NAME}(${BuildConfig.BUILD_TYPE})", + onClickListener = { + try { + val uri = + Uri.parse("https://github.com/Xposed-Modules-Repo/com.lt2333.simplicitytools/releases") + val intent = Intent(Intent.ACTION_VIEW, uri) + startActivity(intent) + } catch (e: Exception) { + Toast.makeText(activity, "访问失败", Toast.LENGTH_SHORT).show() + } + } + ) + ) + ) + } + } + override fun getItems(item: String): ArrayList { return when (item) { aboutName() -> aboutItems() diff --git a/app/src/main/res/drawable/lt.png b/app/src/main/res/drawable/lt.png new file mode 100644 index 00000000..66212c3f Binary files /dev/null and b/app/src/main/res/drawable/lt.png differ diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index b38a047b..7b93bf9c 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -74,5 +74,10 @@ 模块注意事项 确定 查看模块相关信息 + 开源仓库贡献者名单 + 开发者 + 感谢名单 + 第三方开源声明 + 解除安装限制 \ No newline at end of file diff --git a/doc/ThirdPartyOpenSourceStatement.md b/doc/ThirdPartyOpenSourceStatement.md new file mode 100644 index 00000000..3b24ccd0 --- /dev/null +++ b/doc/ThirdPartyOpenSourceStatement.md @@ -0,0 +1,6 @@ +# 第三方开源申明 +ThirdPartyOpenSourceStatement + +##### GNU General Public License v2.0 : +CorePatch - LSPosed +https://github.com/LSPosed/CorePatch \ No newline at end of file