ShortcutBadger library implementation

I want to implement ShortcutBadge, to show counter for push notification on my app icon. gotten from:

i have added the library successfully. my app has class.

and below methods.



i am suppose to use like this:

    int badgeCount = 1;
    ShortcutBadger.applyCount(context, badgeCount);

but cant get it to work when i paste above code on any of my methods on Thanks for your help.

1 answer