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

Commit 589987ce authored by Julia Reynolds's avatar Julia Reynolds
Browse files

Omit notification small icons from history parcel

They aren't shown in the UI, so we can save some work

Test: load notification history page
Fixes: 206973316
Change-Id: Ia5089bd2f051e40f242f9f72528cbb8251ad9684
parent b3f9a846
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -497,7 +497,11 @@ public final class NotificationHistory implements Parcelable {
        p.writeLong(notification.getPostedTimeMs());
        p.writeString(notification.getTitle());
        p.writeString(notification.getText());
        notification.getIcon().writeToParcel(p, flags);
        p.writeBoolean(false);
        // The current design does not display icons, so don't bother adding them to the parcel
        //if (notification.getIcon() != null) {
        //    notification.getIcon().writeToParcel(p, flags);
        //}
    }

    /**
@@ -539,7 +543,9 @@ public final class NotificationHistory implements Parcelable {
        notificationOut.setPostedTimeMs(p.readLong());
        notificationOut.setTitle(p.readString());
        notificationOut.setText(p.readString());
        if (p.readBoolean()) {
            notificationOut.setIcon(Icon.CREATOR.createFromParcel(p));
        }

        return notificationOut.build();
    }