Skip to content

Commit

Permalink
set target api 31
Browse files Browse the repository at this point in the history
  • Loading branch information
MonwF committed Jul 11, 2022
1 parent 1d48f40 commit 2ec9c69
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ android {
applicationId "name.monwf.customiuizer"
minSdkVersion 30
//noinspection OldTargetApi,ExpiredTargetSdkVersion
targetSdkVersion 30
targetSdkVersion 31
versionCode 13
versionName "3.2.1.2207011"
resConfigs 'ru-rRU', 'zh-rCN'
Expand Down
3 changes: 1 addition & 2 deletions app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,7 @@
android:name=".MainApplication"
android:usesCleartextTraffic="true"
android:requestLegacyExternalStorage="true"
tools:ignore="GoogleAppIndexingWarning"
tools:targetApi="q">
tools:ignore="GoogleAppIndexingWarning">

<uses-library android:name="com.miui.system" android:required="false" />
<uses-library android:name="com.miui.core" android:required="false" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3495,7 +3495,7 @@ private static void updateAudioVisualizerState(Context context) {
audioViz.updateViewState(isPlaying, isKeyguardShowing, isNotificationPanelExpanded);
}
public static void AudioVisualizerHook(LoadPackageParam lpparam) {
Helpers.findAndHookMethod("com.android.systemui.statusbar.phone.StatusBar", lpparam.classLoader, "makeStatusBarView", new MethodHook() {
Helpers.hookAllMethods("com.android.systemui.statusbar.phone.StatusBar", lpparam.classLoader, "makeStatusBarView", new MethodHook() {
@Override
protected void after(final MethodHookParam param) throws Throwable {
ViewGroup mNotificationPanel = (ViewGroup)XposedHelpers.getObjectField(param.thisObject, "mNotificationPanel");
Expand Down Expand Up @@ -5167,7 +5167,7 @@ protected void after(MethodHookParam param) throws Throwable {
if (Helpers.is12())
Helpers.findAndHookConstructor("com.android.systemui.miui.controlcenter.QCToggleSliderView", lpparam.classLoader, Context.class, AttributeSet.class, int.class, hook);

Helpers.findAndHookMethod("com.android.systemui.statusbar.phone.StatusBar", lpparam.classLoader, "makeStatusBarView", new MethodHook() {
Helpers.hookAllMethods("com.android.systemui.statusbar.phone.StatusBar", lpparam.classLoader, "makeStatusBarView", new MethodHook() {
@Override
protected void after(final MethodHookParam param) throws Throwable {
LuxListener mLuxListener = new LuxListener();
Expand Down Expand Up @@ -5913,7 +5913,7 @@ protected void after(MethodHookParam param) throws Throwable {
private static long currentTouchTime = 0;

public static void StatusBarGesturesHook(LoadPackageParam lpparam) {
Helpers.findAndHookMethod("com.android.systemui.statusbar.phone.StatusBar", lpparam.classLoader, "makeStatusBarView", new MethodHook() {
Helpers.hookAllMethods("com.android.systemui.statusbar.phone.StatusBar", lpparam.classLoader, "makeStatusBarView", new MethodHook() {
@Override
protected void after(final MethodHookParam param) throws Throwable {
Context mContext = (Context)XposedHelpers.getObjectField(param.thisObject, "mContext");
Expand Down Expand Up @@ -6041,8 +6041,7 @@ protected void before(final MethodHookParam param) throws Throwable {
};

Helpers.findAndHookMethod("com.android.systemui.statusbar.phone.StatusBar", lpparam.classLoader, "interceptTouchEvent", MotionEvent.class, hook);
if (Helpers.is12())
Helpers.findAndHookMethod("com.android.systemui.miui.statusbar.phone.ControlPanelWindowView", lpparam.classLoader, "onTouchEvent", MotionEvent.class, hook);
Helpers.findAndHookMethod("com.android.systemui.controlcenter.phone.ControlPanelWindowView", lpparam.classLoader, "onTouchEvent", MotionEvent.class, hook);
}

public static void ScreenshotConfigHook(LoadPackageParam lpparam) {
Expand Down

0 comments on commit 2ec9c69

Please sign in to comment.