mirror of
https://github.com/LittleTurtle2333/SimplicityTools.git
synced 2026-07-14 12:21:18 +08:00
Compare commits
5 Commits
aafc06dbaa
...
5b78fbbae4
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5b78fbbae4 | ||
|
|
9af50d9dd5 | ||
|
|
c2fa56a90c | ||
|
|
912fee632d | ||
|
|
390be46825 |
@@ -12,8 +12,8 @@ android {
|
||||
applicationId = "com.lt2333.simplicitytools"
|
||||
minSdk = 31
|
||||
targetSdk = 32
|
||||
versionCode = 58
|
||||
versionName = "1.5.7"
|
||||
versionCode = 57
|
||||
versionName = "1.5.6"
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
|
||||
@@ -931,19 +931,6 @@ class SettingsActivity : MIUIActivity() {
|
||||
3
|
||||
)
|
||||
)
|
||||
add(
|
||||
TextV(
|
||||
resId = R.string.maximum_number_of_notification_dots
|
||||
)
|
||||
)
|
||||
add(
|
||||
SeekBarWithTextV(
|
||||
"maximum_number_of_notification_dots",
|
||||
0,
|
||||
4,
|
||||
3
|
||||
)
|
||||
)
|
||||
add(
|
||||
TextSummaryArrowV(
|
||||
TextSummaryV(
|
||||
|
||||
@@ -5,16 +5,18 @@ import com.github.kyuubiran.ezxhelper.utils.hookMethod
|
||||
import com.lt2333.simplicitytools.util.hasEnable
|
||||
import com.lt2333.simplicitytools.util.xposed.base.HookRegister
|
||||
|
||||
object ForceSupportSendApp : HookRegister() {
|
||||
object ForceSupportSendApp: HookRegister() {
|
||||
|
||||
override fun init() {
|
||||
hasEnable("force_support_send_app") {
|
||||
findMethod("com.xiaomi.mirror.synergy.MiuiSynergySdk") {
|
||||
name == "isSupportSendApp"
|
||||
}.hookMethod {
|
||||
after { param ->
|
||||
hasEnable("force_support_send_app") {
|
||||
param.result = true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -6,13 +6,12 @@ import com.lt2333.simplicitytools.util.xposed.base.HookRegister
|
||||
object MaximumNumberOfNotificationIcons: HookRegister() {
|
||||
|
||||
override fun init() {
|
||||
val icons = XSPUtils.getInt("maximum_number_of_notification_icons",3)
|
||||
val dots = XSPUtils.getInt("maximum_number_of_notification_dots",3)
|
||||
val size = XSPUtils.getInt("maximum_number_of_notification_icons",3)
|
||||
"com.android.systemui.statusbar.phone.NotificationIconContainer".replaceMethod(getDefaultClassLoader(), "miuiShowNotificationIcons", Boolean::class.java) {
|
||||
if (it.args[0] as Boolean) {
|
||||
it.thisObject.setIntField("MAX_DOTS", dots)
|
||||
it.thisObject.setIntField("MAX_STATIC_ICONS", icons)
|
||||
it.thisObject.setIntField("MAX_VISIBLE_ICONS_ON_LOCK", icons)
|
||||
it.thisObject.setIntField("MAX_DOTS", size)
|
||||
it.thisObject.setIntField("MAX_STATIC_ICONS", size)
|
||||
it.thisObject.setIntField("MAX_VISIBLE_ICONS_ON_LOCK", size)
|
||||
} else {
|
||||
it.thisObject.setIntField("MAX_DOTS", 0)
|
||||
it.thisObject.setIntField("MAX_STATIC_ICONS", 0)
|
||||
|
||||
@@ -305,8 +305,8 @@ object StatusBarLayout : HookRegister() {
|
||||
(statusIcons.parent as ViewGroup).removeView(statusIcons)
|
||||
(systemIcons.parent as ViewGroup).removeView(systemIcons)
|
||||
(battery.parent as ViewGroup).removeView(battery)
|
||||
(fullscreenNotificationIconArea.parent as ViewGroup).removeView(
|
||||
fullscreenNotificationIconArea
|
||||
(notificationIconAreaInner.parent as ViewGroup).removeView(
|
||||
notificationIconAreaInner
|
||||
)
|
||||
|
||||
val mConstraintLayout =
|
||||
@@ -317,7 +317,7 @@ object StatusBarLayout : HookRegister() {
|
||||
)
|
||||
}
|
||||
|
||||
mConstraintLayout.addView(fullscreenNotificationIconArea)
|
||||
mConstraintLayout.addView(notificationIconAreaInner)
|
||||
mConstraintLayout.addView(battery)
|
||||
|
||||
|
||||
@@ -329,14 +329,14 @@ object StatusBarLayout : HookRegister() {
|
||||
}
|
||||
|
||||
|
||||
fullscreenNotificationIconArea.layoutParams = ConstraintLayout.LayoutParams(
|
||||
notificationIconAreaInner.layoutParams = ConstraintLayout.LayoutParams(
|
||||
0,
|
||||
ConstraintLayout.LayoutParams.MATCH_PARENT
|
||||
).also {
|
||||
it.startToEnd = batteryId
|
||||
it.endToEnd = 0
|
||||
}
|
||||
fullscreenNotificationIconArea.layoutDirection = View.LAYOUT_DIRECTION_RTL
|
||||
notificationIconAreaInner.layoutDirection = View.LAYOUT_DIRECTION_RTL
|
||||
|
||||
|
||||
//增加一个左对齐布局
|
||||
|
||||
@@ -194,6 +194,4 @@
|
||||
<string name="clock_right">Reloj a la derecha</string>
|
||||
<string name="status_bar_layout_mode">Modo de diseño de barra de estado</string>
|
||||
<string name="clock_center_and_icon_left">Centrar reloj e icono a la izquierda</string>
|
||||
<string name="maximum_number_of_notification_icons">Número máximo de iconos de notificación</string>
|
||||
<string name="maximum_number_of_notification_dots">Número máximo de puntos de notificaciones</string>
|
||||
</resources>
|
||||
|
||||
@@ -195,5 +195,4 @@
|
||||
<string name="status_bar_layout_mode">Aspect bară de stare</string>
|
||||
<string name="clock_center_and_icon_left">Ceas la centru și pictograme în stânga</string>
|
||||
<string name="maximum_number_of_notification_icons">Numărul maxim de pictograme de notificare</string>
|
||||
<string name="maximum_number_of_notification_dots">Numărul maxim de puncte de notificare</string>
|
||||
</resources>
|
||||
|
||||
@@ -199,5 +199,4 @@
|
||||
<string name="status_bar_layout_mode">Стиль строки состояния</string>
|
||||
<string name="clock_center_and_icon_left">Часы по центру и иконки слева</string>
|
||||
<string name="maximum_number_of_notification_icons">Максимальное количество значков уведомлений</string>
|
||||
<string name="maximum_number_of_notification_dots">Максимальное количество значков уведомлений</string>
|
||||
</resources>
|
||||
|
||||
@@ -196,5 +196,4 @@
|
||||
<string name="status_bar_layout_mode">Durum çubuğu düzeni modu</string>
|
||||
<string name="clock_center_and_icon_left">Saat Merkezi ve Sol Simge</string>
|
||||
<string name="maximum_number_of_notification_icons">Maksimum bildirim simgesi sayısı</string>
|
||||
<string name="maximum_number_of_notification_dots">Maksimum bildirim noktası sayısı</string>
|
||||
</resources>
|
||||
|
||||
@@ -195,5 +195,4 @@
|
||||
<string name="status_bar_layout_mode">状态栏布局模式</string>
|
||||
<string name="clock_center_and_icon_left">时间居中+左侧图标</string>
|
||||
<string name="maximum_number_of_notification_icons">通知图标最大数量</string>
|
||||
<string name="maximum_number_of_notification_dots">通知点数最大数量</string>
|
||||
</resources>
|
||||
|
||||
@@ -195,5 +195,4 @@
|
||||
<string name="status_bar_layout_mode">狀態欄布局模式</string>
|
||||
<string name="clock_center_and_icon_left">時間居中+圖示置左</string>
|
||||
<string name="maximum_number_of_notification_icons">通知圖示最大數量</string>
|
||||
<string name="maximum_number_of_notification_dots">通知點點數量</string>
|
||||
</resources>
|
||||
|
||||
@@ -199,5 +199,4 @@
|
||||
<string name="status_bar_layout_mode">Status bar layout mode</string>
|
||||
<string name="clock_center_and_icon_left">Clock Center and Icon Left</string>
|
||||
<string name="maximum_number_of_notification_icons">Maximum number of notification icons</string>
|
||||
<string name="maximum_number_of_notification_dots">Maximum number of notification dots</string>
|
||||
</resources>
|
||||
|
||||
Reference in New Issue
Block a user