栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > 后端开发 > Java

android5.1 launcher2去掉桌面应用图标

Java 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

android5.1 launcher2去掉桌面应用图标

1.launcher的桌面应用位置

2.APK源码

3.无源码应用改launcher

//####################################################################//

1.路径:packagesappsLauncher2resxmldefault_workspace.xml

packagesappsLauncher2resxmldefault_workspace.xml

     Licensed under the Apache License, Version 2.0 (the "License");
     you may not use this file except in compliance with the License.
     You may obtain a copy of the License at

          http://www.apache.org/licenses/LICENSE-2.0

     Unless required by applicable law or agreed to in writing, software
     distributed under the License is distributed on an "AS IS" BASIS,
     WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     See the License for the specific language governing permissions and
     limitations under the License.
-->


    

    
    

    
    
    

    
    
    

    

    
    
    
    
    

注解掉了:com.android.settings和com.android.browser

有效果!

launcher:title,图标下面的文字,目前只支持引用,不能直接书写字符串。

launcher:icon,图标引用。

launcher:uri,链接地址。

launcher:packageName,应用程序的包名。

launcher:className,应用程序的启动类名。

launcher:screen,图标所在的屏幕编号。

launcher:x,图标在横向排列上的序号。

launcher:y,图标在纵向排列上的序号。

参考链接:(34条消息) adb安装完apk没有桌面图标 - CSDNhttps://www.csdn.net/tags/NtTacg0sMTM3OTYtYmxvZwO0O0OO0O0O.html

2.APK源码

packagesappsBrowserAndroidManifest.xml

            
            
                
                
           -     
           +     
                
                
            

注解掉               

因为Launcher是根据应用清单文件里,可以作为参考。

3.无源码launcher内改

packagesappsLauncher3srccomandroidlauncher3LauncherModel.java

for (int i = 0; i < apps.size(); i++) {
    LauncherActivityInfoCompat app = apps.get(i);
+    if("com.android.browser".equals(apps.get(i).getApplicationInfo().packageName)){
+        continue;
+    }
    mBgAllAppsList.add(new AppInfo(mContext, app, user, mIconCache, mLabelCache));
}

过滤掉com.android.browser包,仅做参考launcher3修改,launcher2并无找到对呀位置。

参考链接:

(34条消息) Android5.1 Launcher3 隐藏指定应用图标_西门萝卜的博客-CSDN博客_launcher3隐藏应用https://blog.csdn.net/paullovazxq/article/details/52154468?spm=1001.2101.3001.6650.14&utm_medium=distribute.pc_relevant.none-task-blog-2%7Edefault%7EBlogCommendFromBaidu%7Edefault-14-52154468-blog-114277562.pc_relevant_antiscanv4&depth_1-utm_source=distribute.pc_relevant.none-task-blog-2%7Edefault%7EBlogCommendFromBaidu%7Edefault-14-52154468-blog-114277562.pc_relevant_antiscanv4&utm_relevant_index=17

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/992466.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号