1.4.0530 修改主页,爱优读隐藏图标,更换壁纸

This commit is contained in:
2024-05-31 09:47:11 +08:00
parent 5d19b2abb6
commit d48b8126c1
5 changed files with 63 additions and 12 deletions

View File

@@ -71,8 +71,8 @@ android {
// versionName "2.3.9"
//cube
versionCode 126
versionName "1.4.0428"
versionCode 135
versionName "1.4.0530"
ndk {
//选择要添加的对应 cpu 类型的 .so 库。

Binary file not shown.

After

Width:  |  Height:  |  Size: 832 KiB

View File

@@ -86,22 +86,38 @@
launcher:x="3"
launcher:y="0" />
<resolve
<!-- <resolve-->
<!-- launcher:container="-101"-->
<!-- launcher:screen="4"-->
<!-- launcher:x="4"-->
<!-- launcher:y="0">-->
<!-- <favorite launcher:uri="#Intent;action=android.media.action.STILL_IMAGE_CAMERA;end" />-->
<!-- <favorite launcher:uri="#Intent;action=android.intent.action.CAMERA_BUTTON;end" />-->
<!-- </resolve>-->
<!-- <resolve-->
<!-- launcher:container="-101"-->
<!-- launcher:screen="5"-->
<!-- launcher:x="5"-->
<!-- launcher:y="0">-->
<!-- <favorite launcher:uri="#Intent;action=android.intent.action.MAIN;component=com.android.deskclock/.DeskClock;end" />-->
<!-- </resolve>-->
<favorite
launcher:container="-101"
launcher:className="com.aoleyun.sn.activity.update.UpdateActivity"
launcher:packageName="com.aoleyun.sn"
launcher:screen="4"
launcher:x="4"
launcher:y="0">
<favorite launcher:uri="#Intent;action=android.media.action.STILL_IMAGE_CAMERA;end" />
<favorite launcher:uri="#Intent;action=android.intent.action.CAMERA_BUTTON;end" />
</resolve>
launcher:y="0" />
<resolve
<favorite
launcher:container="-101"
launcher:className="com.aoleyun.sn.activity.EyeProtectionActivity"
launcher:packageName="com.aoleyun.sn"
launcher:screen="5"
launcher:x="5"
launcher:y="0">
<favorite launcher:uri="#Intent;action=android.intent.action.MAIN;component=com.android.deskclock/.DeskClock;end" />
</resolve>
launcher:y="0" />
<!-- Bottom row -->
<!-- <resolve-->

View File

@@ -547,7 +547,11 @@ public class Launcher extends BaseDraggingActivity implements LauncherExterns,
//利用WallpaparManager,添加权限set_wallpaper
WallpaperManager wallpaperManager = WallpaperManager.getInstance(this);
try {
wallpaperManager.setBitmap(BitmapFactory.decodeResource(getResources(), R.drawable.wallpapers));
if ("Aiud_A8_ag_1095".equals(Build.MODEL)) {
wallpaperManager.setBitmap(BitmapFactory.decodeResource(getResources(), R.drawable.wallpapers_aiudu));
}else {
wallpaperManager.setBitmap(BitmapFactory.decodeResource(getResources(), R.drawable.wallpapers));
}
} catch (IOException e) {
e.printStackTrace();
Log.e("TT", e.getMessage());

View File

@@ -32,6 +32,7 @@ import android.content.pm.LauncherActivityInfo;
import android.content.pm.PackageInstaller;
import android.content.pm.PackageInstaller.SessionInfo;
import android.content.pm.ShortcutInfo;
import android.os.Build;
import android.os.Handler;
import android.os.Process;
import android.os.UserHandle;
@@ -266,6 +267,25 @@ public class LoaderTask implements Runnable {
this.add("com.android.soundrecorder");
}};
/*爱优读需要隐藏的图标*/
private static final HashSet<String> AiudHideApp = new HashSet<String>() {{
this.add("com.android.email");
this.add("com.android.soundrecorder");
this.add("com.android.documentsui");
this.add("com.mediatek.camera");
this.add("com.aoleyun.browser");
this.add("com.android.music");
this.add("com.android.fmradio");
this.add("com.android.gallery3d");
this.add("com.android.calendar");
this.add("com.android.calculator2");
this.add("com.android.deskclock");
this.add("com.android.contacts");
this.add("com.android.mms");
this.add("com.android.dialer");
this.add("com.android.stk");
}};
/**
* 系统应用只显示这几个
*/
@@ -356,7 +376,18 @@ public class LoaderTask implements Runnable {
}
}
}
if ("Aiud_A8_ag_1095".equals(Build.MODEL)) {
if (AiudHideApp.contains(app.getApplicationInfo().packageName)) {
continue;
}
if ("com.aoleyun.sn".equals(app.getApplicationInfo().packageName) && "com.aoleyun.sn.activity.CleanupActivity".equals(app.getComponentName().getClassName())) {
continue;
}
}
Log.e("verifyApplications", "AddApp: " + app.getApplicationInfo().packageName);
Log.e("verifyApplications", "AddApp: " + app.getApplicationInfo().classLoaderName);
InstallShortcutReceiver.PendingInstallShortcutInfo pendingInstallShortcutInfo = new InstallShortcutReceiver.PendingInstallShortcutInfo(app, context);
added.add(pendingInstallShortcutInfo);
installQueue.add(pendingInstallShortcutInfo.getItemInfo());