[RK3288][Android6.0] 调试笔记 --- Launcher中隐藏APK图标

Platform: Rockchip
OS: Android 6.0
Kernel: 3.10.92

网上大多数是针对apk改动隐藏图标,但是第三方软件不一定可行,这里提供launcher中修改的方法,由网友“境界直指未来”提供分享。
以搜狗输入法为例,报名可以从/data/data/下获取

diff --git a/packages/apps/Launcher3/src/com/android/launcher3/LauncherModel.java b/packages/apps/Launcher3/src/com/android/launcher3/LauncherMo
index 28670f4..742c48c 100755
--- a/packages/apps/Launcher3/src/com/android/launcher3/LauncherModel.java
+++ b/packages/apps/Launcher3/src/com/android/launcher3/LauncherModel.java
@@ -2887,7 +2887,11 @@ public class LauncherModel extends BroadcastReceiver
                 // Create the ApplicationInfos
                 for (int i = 0; i < apps.size(); i++) {
                     LauncherActivityInfoCompat app = apps.get(i);
                    // This builds the icon bitmaps.
+                   if("com.sohu.inputmethod.sogou".equals(apps.get(i).getApplicationInfo().packageName))
+                       continue;  
                     mBgAllAppsList.add(new AppInfo(mContext, app, user, mIconCache, mLabelCache));
                 }

你可能感兴趣的:(子类__Android)