@@ -94,25 +94,25 @@ public class Notification implements Parcelable
9494
9595 /**
9696 * A timestamp related to this notification, in milliseconds since the epoch.
97- *
97+ *
9898 * Default value: {@link System#currentTimeMillis() Now}.
9999 *
100100 * Choose a timestamp that will be most relevant to the user. For most finite events, this
101101 * corresponds to the time the event happened (or will happen, in the case of events that have
102102 * yet to occur but about which the user is being informed). Indefinite events should be
103- * timestamped according to when the activity began.
104- *
103+ * timestamped according to when the activity began.
104+ *
105105 * Some examples:
106- *
106+ *
107107 * <ul>
108108 * <li>Notification of a new chat message should be stamped when the message was received.</li>
109109 * <li>Notification of an ongoing file download (with a progress bar, for example) should be stamped when the download started.</li>
110110 * <li>Notification of a completed file download should be stamped when the download finished.</li>
111111 * <li>Notification of an upcoming meeting should be stamped with the time the meeting will begin (that is, in the future).</li>
112112 * <li>Notification of an ongoing stopwatch (increasing timer) should be stamped with the watch's start time.
113113 * <li>Notification of an ongoing countdown timer should be stamped with the timer's end time.
114- * </ul>
115- *
114+ * </ul>
115+ *
116116 */
117117 public long when ;
118118
@@ -134,13 +134,13 @@ public class Notification implements Parcelable
134134 /**
135135 * The number of events that this notification represents. For example, in a new mail
136136 * notification, this could be the number of unread messages.
137- *
137+ *
138138 * The system may or may not use this field to modify the appearance of the notification. For
139139 * example, before {@link android.os.Build.VERSION_CODES#HONEYCOMB}, this number was
140140 * superimposed over the icon in the status bar. Starting with
141141 * {@link android.os.Build.VERSION_CODES#HONEYCOMB}, the template used by
142142 * {@link Notification.Builder} has displayed the number in the expanded notification view.
143- *
143+ *
144144 * If the number is 0 or negative, it is never shown.
145145 */
146146 public int number ;
@@ -342,7 +342,7 @@ public class Notification implements Parcelable
342342
343343 /**
344344 * Obsolete flag indicating high-priority notifications; use the priority field instead.
345- *
345+ *
346346 * @deprecated Use {@link #priority} with a positive value.
347347 */
348348 public static final int FLAG_HIGH_PRIORITY = 0x00000080 ;
@@ -383,15 +383,15 @@ public class Notification implements Parcelable
383383
384384 /**
385385 * Relative priority for this notification.
386- *
386+ *
387387 * Priority is an indication of how much of the user's valuable attention should be consumed by
388388 * this notification. Low-priority notifications may be hidden from the user in certain
389389 * situations, while the user might be interrupted for a higher-priority notification. The
390- * system will make a determination about how to interpret notification priority as described in
390+ * system will make a determination about how to interpret notification priority as described in
391391 * MUMBLE MUMBLE.
392392 */
393393 public int priority ;
394-
394+
395395 /**
396396 * @hide
397397 * Notification type: incoming call (voice or video) or similar synchronous communication request.
@@ -642,7 +642,7 @@ public Notification clone() {
642642 that .flags = this .flags ;
643643
644644 that .priority = this .priority ;
645-
645+
646646 final String [] thiskind = this .kind ;
647647 if (thiskind != null ) {
648648 final int N = thiskind .length ;
@@ -741,9 +741,9 @@ public void writeToParcel(Parcel parcel, int flags)
741741 }
742742
743743 parcel .writeInt (priority );
744-
744+
745745 parcel .writeStringArray (kind ); // ok for null
746-
746+
747747 if (extras != null ) {
748748 parcel .writeInt (1 );
749749 extras .writeToParcel (parcel , 0 );
@@ -895,16 +895,16 @@ public String toString() {
895895
896896 /**
897897 * Builder class for {@link Notification} objects.
898- *
898+ *
899899 * Provides a convenient way to set the various fields of a {@link Notification} and generate
900900 * content views using the platform's notification layout template. If your app supports
901901 * versions of Android as old as API level 4, you can instead use
902902 * {@link android.support.v4.app.NotificationCompat.Builder NotificationCompat.Builder},
903903 * available in the <a href="{@docRoot}tools/extras/support-library.html">Android Support
904904 * library</a>.
905- *
905+ *
906906 * <p>Example:
907- *
907+ *
908908 * <pre class="prettyprint">
909909 * Notification noti = new Notification.Builder(mContext)
910910 * .setContentTitle("New mail from " + sender.toString())
@@ -993,8 +993,8 @@ public Builder setWhen(long when) {
993993
994994 /**
995995 * Show the {@link Notification#when} field as a stopwatch.
996- *
997- * Instead of presenting <code>when</code> as a timestamp, the notification will show an
996+ *
997+ * Instead of presenting <code>when</code> as a timestamp, the notification will show an
998998 * automatically updating display of the minutes and seconds since <code>when</code>.
999999 *
10001000 * Useful when showing an elapsed time (like an ongoing phone call).
@@ -1060,7 +1060,7 @@ public Builder setContentText(CharSequence text) {
10601060 }
10611061
10621062 /**
1063- * Set the third line of text in the platform notification template.
1063+ * Set the third line of text in the platform notification template.
10641064 * Don't use if you're also using {@link #setProgress(int, int, boolean)}; they occupy the same location in the standard template.
10651065 */
10661066 public Builder setSubText (CharSequence text ) {
@@ -1322,12 +1322,12 @@ public Builder setPriority(int pri) {
13221322 mPriority = pri ;
13231323 return this ;
13241324 }
1325-
1325+
13261326 /**
13271327 * @hide
1328- *
1328+ *
13291329 * Add a kind (category) to this notification. Optional.
1330- *
1330+ *
13311331 * @see Notification#kind
13321332 */
13331333 public Builder addKind (String k ) {
@@ -1353,6 +1353,8 @@ public Builder setExtras(Bundle bag) {
13531353 /**
13541354 * Add an action to this notification. Actions are typically displayed by
13551355 * the system as a button adjacent to the notification content.
1356+ * <br>
1357+ * A notification displays up to 3 actions, from left to right in the order they were added.
13561358 *
13571359 * @param icon Resource ID of a drawable that represents the action.
13581360 * @param title Text describing the action.
@@ -1532,7 +1534,7 @@ private RemoteViews makeBigContentView() {
15321534
15331535 private RemoteViews generateActionButton (Action action ) {
15341536 final boolean tombstone = (action .actionIntent == null );
1535- RemoteViews button = new RemoteViews (mContext .getPackageName (),
1537+ RemoteViews button = new RemoteViews (mContext .getPackageName (),
15361538 tombstone ? R .layout .notification_action_tombstone
15371539 : R .layout .notification_action );
15381540 button .setTextViewCompoundDrawables (R .id .action0 , action .icon , 0 , 0 , 0 );
@@ -1691,7 +1693,7 @@ protected RemoteViews getStandardView(int layoutId) {
16911693
16921694 /**
16931695 * Helper class for generating large-format notifications that include a large image attachment.
1694- *
1696+ *
16951697 * This class is a "rebuilder": It consumes a Builder object and modifies its behavior, like so:
16961698 * <pre class="prettyprint">
16971699 * Notification noti = new Notification.BigPictureStyle(
@@ -1703,7 +1705,7 @@ protected RemoteViews getStandardView(int layoutId) {
17031705 * .bigPicture(aBigBitmap)
17041706 * .build();
17051707 * </pre>
1706- *
1708+ *
17071709 * @see Notification#bigContentView
17081710 */
17091711 public static class BigPictureStyle extends Style {
@@ -1774,7 +1776,7 @@ public Notification build() {
17741776
17751777 /**
17761778 * Helper class for generating large-format notifications that include a lot of text.
1777- *
1779+ *
17781780 * This class is a "rebuilder": It consumes a Builder object and modifies its behavior, like so:
17791781 * <pre class="prettyprint">
17801782 * Notification noti = new Notification.BigPictureStyle(
@@ -1786,7 +1788,7 @@ public Notification build() {
17861788 * .bigText(aVeryLongString)
17871789 * .build();
17881790 * </pre>
1789- *
1791+ *
17901792 * @see Notification#bigContentView
17911793 */
17921794 public static class BigTextStyle extends Style {
@@ -1831,7 +1833,7 @@ private RemoteViews makeBigContentView() {
18311833 mBuilder .mContentText = null ;
18321834
18331835 RemoteViews contentView = getStandardView (R .layout .notification_template_big_text );
1834-
1836+
18351837 if (hadThreeLines ) {
18361838 // vertical centering
18371839 contentView .setViewPadding (R .id .line1 , 0 , 0 , 0 , 0 );
@@ -1855,7 +1857,7 @@ public Notification build() {
18551857
18561858 /**
18571859 * Helper class for generating large-format notifications that include a list of (up to 5) strings.
1858- *
1860+ *
18591861 * This class is a "rebuilder": It consumes a Builder object and modifies its behavior, like so:
18601862 * <pre class="prettyprint">
18611863 * Notification noti = new Notification.InboxStyle(
@@ -1870,7 +1872,7 @@ public Notification build() {
18701872 * .setSummaryText("+3 more")
18711873 * .build();
18721874 * </pre>
1873- *
1875+ *
18741876 * @see Notification#bigContentView
18751877 */
18761878 public static class InboxStyle extends Style {
0 commit comments