Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 44098524 authored by Jeff DeCew's avatar Jeff DeCew Committed by Android (Google) Code Review
Browse files

Merge "Make the fallback nature of message text clear from the docs." into main

parents d3a670bf 3df6df00
Loading
Loading
Loading
Loading
+18 −2
Original line number Diff line number Diff line
@@ -8725,6 +8725,12 @@ public class Notification implements Parcelable
         * <p>The messages should be added in chronologic order, i.e. the oldest first,
         * the newest last.
         *
         * <p>Multiple Messages in a row with the same timestamp and sender may be grouped as a
         * single message. This means an app should represent a message that has both an image and
         * text as two Message objects, one with the image (and fallback text), and the other with
         * the message text. For consistency, a text message (if any) should be provided after Uri
         * content.
         *
         * @param message The {@link Message} to be displayed
         * @return this object for method chaining
         */
@@ -9359,6 +9365,15 @@ public class Notification implements Parcelable
            }
        }
        /*
         * An object representing a simple message or piece of media within a mixed-media message.
         *
         * This object can only represent text or a single binary piece of media. For apps which
         * support mixed-media messages (e.g. text + image), multiple Messages should be used, one
         * to represent each piece of the message, and they should all be given the same timestamp.
         * For consistency, a text message should be added last of all Messages with the same
         * timestamp.
         */
        public static final class Message {
            /** @hide */
            public static final String KEY_TEXT = "text";
@@ -9447,8 +9462,9 @@ public class Notification implements Parcelable
            /**
             * Sets a binary blob of data and an associated MIME type for a message. In the case
             * where the platform doesn't support the MIME type, the original text provided in the
             * constructor will be used.
             * where the platform or the UI state doesn't support the MIME type, the original text
             * provided in the constructor will be used.  When this data can be presented to the
             * user, the original text will only be used as accessibility text.
             * @param dataMimeType The MIME type of the content. See
             * {@link android.graphics.ImageDecoder#isMimeTypeSupported(String)} for a list of
             * supported image MIME types.