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

Commit b21759fb authored by Jeff DeCew's avatar Jeff DeCew
Browse files

Deprecate Notification.Builder.createContentView APIs

Fixes: 320735431
Test: na
Flag: NONE
Change-Id: I042963d9810acbf50156dcc0b08157c9f69397ae
parent 315f5137
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -6582,9 +6582,9 @@ package android.app {
    method @Deprecated public android.app.Notification.Builder addPerson(String);
    method @NonNull public android.app.Notification.Builder addPerson(android.app.Person);
    method @NonNull public android.app.Notification build();
    method public android.widget.RemoteViews createBigContentView();
    method public android.widget.RemoteViews createContentView();
    method public android.widget.RemoteViews createHeadsUpContentView();
    method @Deprecated public android.widget.RemoteViews createBigContentView();
    method @Deprecated public android.widget.RemoteViews createContentView();
    method @Deprecated public android.widget.RemoteViews createHeadsUpContentView();
    method @NonNull public android.app.Notification.Builder extend(android.app.Notification.Extender);
    method public android.os.Bundle getExtras();
    method @Deprecated public android.app.Notification getNotification();
+36 −6
Original line number Diff line number Diff line
@@ -6020,11 +6020,19 @@ public class Notification implements Parcelable
        }
        /**
         * Construct a RemoteViews for the final 1U notification layout. In order:
         *   1. Custom contentView from the caller
         *   2. Style's proposed content view
         *   3. Standard template view
         * Construct a RemoteViews representing the standard notification layout.
         *
         * @deprecated For performance and system health reasons, this API is no longer required to
         *  be used directly by the System UI when rendering Notifications to the user. While the UI
         *  returned by this method will still represent the content of the Notification being
         *  built, it may differ from the visual style of the system.
         *
         *  NOTE: this API has always had severe limitations; for example it does not support any
         *  interactivity, it ignores the app theme, it hard-codes the colors from the system theme
         *  at the time it is called, and it does Bitmap decoding on the main thread which can cause
         *  UI jank.
         */
        @Deprecated
        public RemoteViews createContentView() {
            return createContentView(false /* increasedheight */ );
        }
@@ -6133,8 +6141,19 @@ public class Notification implements Parcelable
        }
        /**
         * Construct a RemoteViews for the final big notification layout.
         * Construct a RemoteViews representing the expanded notification layout.
         *
         * @deprecated For performance and system health reasons, this API is no longer required to
         *  be used directly by the System UI when rendering Notifications to the user. While the UI
         *  returned by this method will still represent the content of the Notification being
         *  built, it may differ from the visual style of the system.
         *
         *  NOTE: this API has always had severe limitations; for example it does not support any
         *  interactivity, it ignores the app theme, it hard-codes the colors from the system theme
         *  at the time it is called, and it does Bitmap decoding on the main thread which can cause
         *  UI jank.
         */
        @Deprecated
        public RemoteViews createBigContentView() {
            RemoteViews result = null;
            if (useExistingRemoteView(mN.bigContentView)) {
@@ -6267,8 +6286,19 @@ public class Notification implements Parcelable
        }
        /**
         * Construct a RemoteViews for the final heads-up notification layout.
         * Construct a RemoteViews representing the heads up notification layout.
         *
         * @deprecated For performance and system health reasons, this API is no longer required to
         *  be used directly by the System UI when rendering Notifications to the user. While the UI
         *  returned by this method will still represent the content of the Notification being
         *  built, it may differ from the visual style of the system.
         *
         *  NOTE: this API has always had severe limitations; for example it does not support any
         *  interactivity, it ignores the app theme, it hard-codes the colors from the system theme
         *  at the time it is called, and it does Bitmap decoding on the main thread which can cause
         *  UI jank.
         */
        @Deprecated
        public RemoteViews createHeadsUpContentView() {
            return createHeadsUpContentView(false /* useIncreasedHeight */);
        }