Created
April 1, 2015 00:42
-
-
Save yakdere/21dcaa2f1256233d902b to your computer and use it in GitHub Desktop.
Wearables
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void sendLocalNotification() { | |
PendingIntent pendingIntent = PendingIntent.getActivity(this, id , launcherIntent, 0); | |
Notification notification = new NotificationCompat.Builder(this) | |
.setContentTitle(title) | |
.setContentText(body) | |
.setSmallIcon(_icon_small) | |
.setLargeIcon(_icon_large) | |
.addAction(R.drawable.action, “action title”, pendingIntent).build(); | |
NotificationManagerCompat.from(this).notify(id, notification); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment