From 02f710fc0f16694922800d8b130f1320a92bd407 Mon Sep 17 00:00:00 2001 From: M66B Date: Fri, 16 Jun 2023 16:41:10 +0200 Subject: [PATCH] Revert "Honor badger" This reverts commit f049fb0cad0d137271c97796763d332043110ab3. --- FAQ.md | 3 -- app/src/amazon/AndroidManifest.xml | 5 --- app/src/fdroid/AndroidManifest.xml | 5 --- app/src/github/AndroidManifest.xml | 5 --- app/src/main/AndroidManifest.xml | 5 --- .../leolin/shortcutbadger/ShortcutBadger.java | 2 -- .../shortcutbadger/impl/HonorHomeBadger.java | 34 ------------------- app/src/play/AndroidManifest.xml | 5 --- 8 files changed, 64 deletions(-) delete mode 100644 app/src/main/java/me/leolin/shortcutbadger/impl/HonorHomeBadger.java diff --git a/FAQ.md b/FAQ.md index dd34539f01..43697bade9 100644 --- a/FAQ.md +++ b/FAQ.md @@ -445,9 +445,6 @@ The following permissions are needed to show the count of unread messages as a b * *com.huawei.android.launcher.permission.CHANGE_BADGE* * *com.huawei.android.launcher.permission.READ_SETTINGS* * *com.huawei.android.launcher.permission.WRITE_SETTINGS* -* *com.hihonor.android.launcher.permission.CHANGE_BADGE* -* *com.hihonor.android.launcher.permission.READ_SETTINGS* -* *com.hihonor.android.launcher.permission.WRITE_SETTINGS* * *android.permission.READ_APP_BADGE* * *com.oppo.launcher.permission.READ_SETTINGS* * *com.oppo.launcher.permission.WRITE_SETTINGS* diff --git a/app/src/amazon/AndroidManifest.xml b/app/src/amazon/AndroidManifest.xml index 4dbae788de..cf7475ae97 100644 --- a/app/src/amazon/AndroidManifest.xml +++ b/app/src/amazon/AndroidManifest.xml @@ -55,11 +55,6 @@ - - - - - diff --git a/app/src/fdroid/AndroidManifest.xml b/app/src/fdroid/AndroidManifest.xml index 1a86c91bbb..5ea3b6803b 100644 --- a/app/src/fdroid/AndroidManifest.xml +++ b/app/src/fdroid/AndroidManifest.xml @@ -57,11 +57,6 @@ - - - - - diff --git a/app/src/github/AndroidManifest.xml b/app/src/github/AndroidManifest.xml index 189c01a7d4..627db307f2 100644 --- a/app/src/github/AndroidManifest.xml +++ b/app/src/github/AndroidManifest.xml @@ -57,11 +57,6 @@ - - - - - diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 46f25bf04d..be99be32ac 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -55,11 +55,6 @@ - - - - - diff --git a/app/src/main/java/me/leolin/shortcutbadger/ShortcutBadger.java b/app/src/main/java/me/leolin/shortcutbadger/ShortcutBadger.java index d51419a2e4..fa0ffa11a1 100644 --- a/app/src/main/java/me/leolin/shortcutbadger/ShortcutBadger.java +++ b/app/src/main/java/me/leolin/shortcutbadger/ShortcutBadger.java @@ -21,7 +21,6 @@ import me.leolin.shortcutbadger.impl.AsusHomeBadger; import me.leolin.shortcutbadger.impl.DefaultBadger; import me.leolin.shortcutbadger.impl.EverythingMeHomeBadger; import me.leolin.shortcutbadger.impl.HuaweiHomeBadger; -import me.leolin.shortcutbadger.impl.HonorHomeBadger; import me.leolin.shortcutbadger.impl.NewHtcHomeBadger; import me.leolin.shortcutbadger.impl.NovaHomeBadger; import me.leolin.shortcutbadger.impl.OPPOHomeBader; @@ -55,7 +54,6 @@ public final class ShortcutBadger { BADGERS.add(SonyHomeBadger.class); BADGERS.add(AsusHomeBadger.class); BADGERS.add(HuaweiHomeBadger.class); - BADGERS.add(HonorHomeBadger.class); BADGERS.add(OPPOHomeBader.class); BADGERS.add(SamsungHomeBadger.class); BADGERS.add(ZukHomeBadger.class); diff --git a/app/src/main/java/me/leolin/shortcutbadger/impl/HonorHomeBadger.java b/app/src/main/java/me/leolin/shortcutbadger/impl/HonorHomeBadger.java deleted file mode 100644 index 0232c6ebd2..0000000000 --- a/app/src/main/java/me/leolin/shortcutbadger/impl/HonorHomeBadger.java +++ /dev/null @@ -1,34 +0,0 @@ -package me.leolin.shortcutbadger.impl; - -import android.content.ComponentName; -import android.content.Context; -import android.net.Uri; -import android.os.Bundle; - -import java.util.Arrays; -import java.util.List; - -import me.leolin.shortcutbadger.Badger; -import me.leolin.shortcutbadger.ShortcutBadgeException; - -/** - * @author Jason Ling - */ -public class HonorHomeBadger implements Badger { - - @Override - public void executeBadge(Context context, ComponentName componentName, int badgeCount) throws ShortcutBadgeException { - Bundle localBundle = new Bundle(); - localBundle.putString("package", context.getPackageName()); - localBundle.putString("class", componentName.getClassName()); - localBundle.putInt("badgenumber", badgeCount); - context.getContentResolver().call(Uri.parse("content://com.hihonor.android.launcher.settings/badge/"), "change_badge", null, localBundle); - } - - @Override - public List getSupportLaunchers() { - return Arrays.asList( - "com.hihonor.android.launcher" - ); - } -} diff --git a/app/src/play/AndroidManifest.xml b/app/src/play/AndroidManifest.xml index fd00a46457..2f0be1c3e2 100644 --- a/app/src/play/AndroidManifest.xml +++ b/app/src/play/AndroidManifest.xml @@ -55,11 +55,6 @@ - - - - -