Skip to content

Instantly share code, notes, and snippets.

@hitherejoe
Created June 12, 2017 21:02
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
val notificationID = 2
val messageCount = 8
val notification = Notification.Builder(this, id)
.setContentTitle(getString(R.string.title_discounts))
.setContentText(getString(R.string.description_discounts))
.setSmallIcon(R.drawable.ic_airplanemode_active_grey_24dp)
.setBadgeIconType(BADGE_ICON_SMALL)
.setNumber(messageCount)
.build()
notificationManager.notify(notificationID, notification)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment