Push notification Icon cocos2d-x

0 votes
Hello!

 

How do I change the (i) image of my push notification message to my app's icon.

 

Thanks
asked Mar 20, 2015 in App42 Cloud API-BaaS by jvfiel (35 points)

1 Answer

0 votes

Hey,  If you are building android appliation using cocos2d, you can't use android resource directly.

If you want to change Push Notification icon you can try following code snippet in App42GCMService.java file of Android project.

int resourceID = getResources().getIdentifier("icon", "drawable", "Application package name");

notification.setSmallIcon(resourceID)

Thankx

Vishnu

 

answered Mar 22, 2015 by Vishnu Garg (674 points)
hello thanks!
Download Widgets
Welcome to ShepHertz Product line forum, where you can ask questions and receive answers from the community. You can also reach out to us on support@shephertz.com
...