mirror of
https://github.com/LittleTurtle2333/SimplicityTools.git
synced 2026-07-12 19:31:17 +08:00
@@ -745,6 +745,13 @@ class SettingsActivity : MIUIActivity() {
|
|||||||
SwitchV("notification_weather_city"),
|
SwitchV("notification_weather_city"),
|
||||||
dataBindingRecv = showWeatherMainSwitchBinding.binding.getRecv(2)
|
dataBindingRecv = showWeatherMainSwitchBinding.binding.getRecv(2)
|
||||||
)
|
)
|
||||||
|
TextSummaryWithSwitch(
|
||||||
|
TextSummaryV(
|
||||||
|
textId = R.string.can_notification_slide,
|
||||||
|
tipsId = R.string.can_notification_slide_summary,
|
||||||
|
),
|
||||||
|
SwitchV("can_notification_slide"),
|
||||||
|
)
|
||||||
Line()
|
Line()
|
||||||
TitleText(resId = R.string.control_center)
|
TitleText(resId = R.string.control_center)
|
||||||
val controlCenterWeatherBinding = GetDataBinding(object : DefValue {
|
val controlCenterWeatherBinding = GetDataBinding(object : DefValue {
|
||||||
|
|||||||
@@ -41,6 +41,7 @@ object SystemUI: AppRegister() {
|
|||||||
StatusBarBigMobileTypeIcon, //大移动类型
|
StatusBarBigMobileTypeIcon, //大移动类型
|
||||||
BatteryPercentage, //电量百分比
|
BatteryPercentage, //电量百分比
|
||||||
CustomMobileTypeText, //自定义移动类型文本
|
CustomMobileTypeText, //自定义移动类型文本
|
||||||
|
CanNotificationSlide, //允许下滑通知打开小窗
|
||||||
LockScreenClockDisplaySeconds, // 锁屏时钟显示秒
|
LockScreenClockDisplaySeconds, // 锁屏时钟显示秒
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package com.lt2333.simplicitytools.hook.app.systemui
|
||||||
|
|
||||||
|
import com.github.kyuubiran.ezxhelper.utils.findMethod
|
||||||
|
import com.github.kyuubiran.ezxhelper.utils.hookMethod
|
||||||
|
import com.lt2333.simplicitytools.util.hasEnable
|
||||||
|
import com.lt2333.simplicitytools.util.xposed.base.HookRegister
|
||||||
|
|
||||||
|
object CanNotificationSlide: HookRegister() {
|
||||||
|
|
||||||
|
override fun init() {
|
||||||
|
findMethod("com.android.systemui.statusbar.notification.NotificationSettingsManager") {
|
||||||
|
name == "canSlide"
|
||||||
|
}.hookMethod {
|
||||||
|
after { param ->
|
||||||
|
hasEnable("can_notification_slide") {
|
||||||
|
param.result = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -181,7 +181,7 @@
|
|||||||
<string name="left">Left</string>
|
<string name="left">Left</string>
|
||||||
<string name="right">Right</string>
|
<string name="right">Right</string>
|
||||||
<string name="big_mobile_type_icon">Big Mobile Type Icon</string>
|
<string name="big_mobile_type_icon">Big Mobile Type Icon</string>
|
||||||
<string name="can_notification_slide">Make all notification can be slide to small window</string>
|
<string name="can_notification_slide">Make most notifications can be slide to small window</string>
|
||||||
<string name="battery_percentage_font_size">Battery percentage font size</string>
|
<string name="battery_percentage_font_size">Battery percentage font size</string>
|
||||||
<string name="zero_do_no_change">0: do not change</string>
|
<string name="zero_do_no_change">0: do not change</string>
|
||||||
<string name="big_mobile_type_icon_size">Big mobile type icon size</string>
|
<string name="big_mobile_type_icon_size">Big mobile type icon size</string>
|
||||||
@@ -219,4 +219,5 @@
|
|||||||
<string name="allow_untrusted_touches">Allow untrusted touches</string>
|
<string name="allow_untrusted_touches">Allow untrusted touches</string>
|
||||||
<string name="take_effect_after_reboot">Take effect after reboot</string>
|
<string name="take_effect_after_reboot">Take effect after reboot</string>
|
||||||
<string name="media_volume_steps_summary">Turning on may cause the scrolling of the volume bar to freeze or the Bluetooth volume to be abnormal</string>
|
<string name="media_volume_steps_summary">Turning on may cause the scrolling of the volume bar to freeze or the Bluetooth volume to be abnormal</string>
|
||||||
|
<string name="can_notification_slide_summary">Some notifications through Mi Push may not be supported.</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|||||||
Reference in New Issue
Block a user