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

Commit ec67cd33 authored by Eric Miao's avatar Eric Miao
Browse files

Keep ashmem bitmap in MediaDescription#setIconBitmap()

When flag "media_description_ashmem_bitmap" is enabled,
`MediaDescription#build()` will call `Bitmap#asShared` for the icon
bitmap when flag "media_description_ashmem_bitmap" is enabled. This
improves performance by using ashmem for subsequent parcelings of
the bitmap.  However, when `MediaDescription#build()` is called
multiple times, multiple ashmem bitmaps will be created as part of
multiple callings of `Bitmap#asShared()`. This change fixes this
problem by keeping the ashmem bitmap directly in `setIconBitmap()`.

Bug: 415375145
Flag: EXEMPT - bugfix

Change-Id: I43af899d73e9d06a4a1fb440a55a6ac942b4affb
parent 4c922b1d
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment