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

Commit bdc1c02d authored by Jacqueline Bronger's avatar Jacqueline Bronger
Browse files

TV PiP: don't load app provided icon from URI

Bug: 278246687
Test: manually, with the PoC app attached to the bug
Change-Id: I7fdcab6774bdeba27f11caa4a1262d07fc8536e2
parent 3d505196
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -94,6 +94,10 @@ public class TvWindowMenuActionButton extends RelativeLayout {
        mCurrentIcon = icon;
        // Remove old image while waiting for the new one to load.
        mIconImageView.setImageDrawable(null);
        if (icon.getType() == Icon.TYPE_URI || icon.getType() == Icon.TYPE_URI_ADAPTIVE_BITMAP) {
            // Disallow loading icon from content URI
            return;
        }
        icon.loadDrawableAsync(mContext, d -> {
            // The image hasn't been set any other way and the drawable belongs to the most
            // recently set Icon.