Skip to content

Commit

Permalink
Update
Browse files Browse the repository at this point in the history
  • Loading branch information
Chipppppppppp committed Jan 21, 2024
1 parent 33508f6 commit 2a6b3ef
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions app/src/main/java/io/github/chipppppppppp/lime/Main.java
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ public void handleLoadPackage(XC_LoadPackage.LoadPackageParam lparam) throws Thr

Class hookTarget;

if (deleteVoom || deleteWallet || deleteIconLabels) {
if (deleteVoom || deleteWallet) {
hookTarget = lparam.classLoader.loadClass("jp.naver.line.android.activity.main.MainActivity");
XposedHelpers.findAndHookMethod(hookTarget, "onResume", new XC_MethodHook() {
@Override
Expand All @@ -49,13 +49,16 @@ protected void beforeHookedMethod(MethodHookParam param) throws Throwable {
if (distributeEvenly) activity.findViewById(walletSpacerResId).setVisibility(View.GONE);
activity.findViewById(walletResId).setVisibility(View.GONE);
}
if (deleteIconLabels) {
String[] resNames = {"bnb_home_v2", "bnb_chat", "bnb_timeline", "bnb_news", "bnb_call", "bnb_wallet"};
for (String resName : resNames) {
int resId = activity.getResources().getIdentifier(resName, "id", activity.getPackageName());
((ViewGroup) activity.findViewById(resId)).getChildAt(5).setVisibility(View.GONE);
}
}
}
});
}

if (deleteIconLabels) {
hookTarget = lparam.classLoader.loadClass("jp.naver.line.android.activity.main.bottomnavigationbar.BottomNavigationBarTextView");
XposedBridge.hookAllConstructors(hookTarget, new XC_MethodHook() {
@Override
protected void afterHookedMethod(MethodHookParam param) throws Throwable {
((View) param.thisObject).setVisibility(View.GONE);
}
});
}
Expand Down

0 comments on commit 2a6b3ef

Please sign in to comment.