summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author David Friedman <dmail@google.com> 2016-05-13 02:42:58 +0000
committer android-build-merger <android-build-merger@google.com> 2016-05-13 02:42:58 +0000
commit938fff13e4084232d43e2450afa59d5955d2d8d0 (patch)
treeecdf22b32fa0e237026853e8bdbe988d9b5852de
parentccfda4ecd8623a2560d907293be0ba5451d07852 (diff)
parent87ec2a13488163b8ed51493a8f4b30165272c847 (diff)
Merge "docs: Continue CL of notifications updates" into mnc-io-docs am: 272db39ad8
am: 87ec2a1348 * commit '87ec2a13488163b8ed51493a8f4b30165272c847': docs: Continue CL of notifications updates Change-Id: I8fb81d096b30c4bb5ac52c1bad3a883492acc45c
-rw-r--r--docs/html/preview/features/notification-updates.jd23
1 files changed, 16 insertions, 7 deletions
diff --git a/docs/html/preview/features/notification-updates.jd b/docs/html/preview/features/notification-updates.jd
index b8dfbaababca..c40536053f76 100644
--- a/docs/html/preview/features/notification-updates.jd
+++ b/docs/html/preview/features/notification-updates.jd
@@ -204,6 +204,16 @@ notificationManager.notify(notificationId, repliedNotification);
android.support.v4.app.RemoteInput}, you can update the reply history
using the {@code setRemoteInputHistory()} method.
</p>
+
+<p>
+ The notification must be either updated or cancelled after the app has
+ received remote input. When the user replies to a remote update
+ using Direct Reply,
+ do not cancel the notification. Instead, update the notification to display the user's reply. You can update the notification using a
+ <code>MessagingStyle</code>, or you can append the user's reply to the remote
+ input history.
+</p>
+
<h2 id="bundle">Bundled Notifications</h2>
<p>Android N provides developers with a new way to represent
@@ -364,7 +374,7 @@ Notification notification = new Notification.Builder()
</pre>
-<h2 id="style">Message Style</h2>
+<h2 id="style">Messaging Style</h2>
<p>
Android N introduces a new API for customizing the style of a notification.
Using the <code>MessageStyle</code> class, you can change several of the
@@ -380,10 +390,9 @@ Notification notification = new Notification.Builder()
<pre>
Notification notification = new Notification.Builder()
.setStyle(new Notification.MessagingStyle("Me")
- .setConversationTitle("Team lunch")
- .addMessage("Hi", timestamp1, null) // Pass in null for user.
- .addMessage("What's up?", timestamp2, "Coworker")
- .addMessage("Not much", timestamp3, null)
- .addMessage("How about lunch?", timestamp4, "Coworker")
- .setAllow());
+ .setConversationTitle("Team lunch")
+ .addMessage("Hi", timestamp1, null) // Pass in null for user.
+ .addMessage("What's up?", timestamp2, "Coworker")
+ .addMessage("Not much", timestamp3, null)
+ .addMessage("How about lunch?", timestamp4, "Coworker"));
</pre> \ No newline at end of file