Skip to content

Files

Latest commit

author
zhengluqiang
Nov 6, 2017
977d730 · Nov 6, 2017

History

History
40 lines (19 loc) · 1.08 KB

README.md

File metadata and controls

40 lines (19 loc) · 1.08 KB

BadgeNumberManager

An Android library supports badge notification like iOS in Huawei, Xiaomi, OPPO and vivo launchers.

Demo Screenshot

Usage

This library supports badge notification like iOS in Huawei, Xiaomi, OPPO and vivo launchers.

In order to support Huawei(华为) launcher,we need to declare a permission in AndroidManifest:

<uses-permission android:name="com.huawei.android.launcher.permission.CHANGE_BADGE"/>

and then,just set the BadgeNumber like this:

BadgeNumberManager.from(context).setBadgeNumber(num)

More detail

For more detail,please check these articles:

简书专栏:有关Android应用桌面角标(BadgeNumber)实现的探讨

知乎专栏:有关Android应用桌面角标(BadgeNumber)实现的探讨

掘金专栏:有关Android应用桌面角标(BadgeNumber)实现的探讨