-
Notifications
You must be signed in to change notification settings - Fork 163
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: home - recents - Show launcher as background
from XiaomiHelper by HowieHChen
- Loading branch information
Showing
6 changed files
with
89 additions
and
0 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
46 changes: 46 additions & 0 deletions
46
app/src/main/java/com/sevtinge/hyperceiler/module/hook/home/recent/ShowLaunch.java
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,46 @@ | ||
/* | ||
* This file is part of HyperCeiler. | ||
* HyperCeiler is free software: you can redistribute it and/or modify | ||
* it under the terms of the GNU Affero General Public License as | ||
* published by the Free Software Foundation, either version 3 of the | ||
* License. | ||
* This program is distributed in the hope that it will be useful, | ||
* but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
* GNU Affero General Public License for more details. | ||
* You should have received a copy of the GNU Affero General Public License | ||
* along with this program. If not, see <https://www.gnu.org/licenses/>. | ||
* Copyright (C) 2023-2024 HyperCeiler Contributions | ||
*/ | ||
package com.sevtinge.hyperceiler.module.hook.home.recent; | ||
|
||
import com.sevtinge.hyperceiler.module.base.BaseHook; | ||
|
||
public class ShowLaunch extends BaseHook { | ||
//from XiaomiHelper by HowieHChen | ||
@Override | ||
public void init() throws NoSuchMethodException { | ||
findAndHookMethod("com.miui.home.recents.NavStubView", "changeAlphaScaleForFsGesture", float.class, float.class, new MethodHook(){ | ||
@Override | ||
protected void before(MethodHookParam param) throws Throwable { | ||
param.args[0] = 1.0f; | ||
} | ||
}); | ||
findAndHookMethod("com.miui.home.recents.OverviewState", "getShortcutMenuLayerAlpha", new MethodHook(){ | ||
@Override | ||
protected void before(MethodHookParam param) throws Throwable { | ||
param.setResult(1.0f); | ||
} | ||
}); | ||
findAndHookMethod("com.miui.home.recents.OverviewState", "getShortcutMenuLayerScale", new MethodHook(){ | ||
@Override | ||
protected void before(MethodHookParam param) throws Throwable { | ||
param.setResult((float) mPrefsMap.getInt("home_recent_show_launch_size", 95) / 100); | ||
} | ||
}); | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
app/src/main/java/com/sevtinge/hyperceiler/module/hook/home/title/AppBlurAnim.kt
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
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
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
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