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

Skip to content
Commit eea02253 authored by Winson Chung's avatar Winson Chung
Browse files

Fixing minor memory leak with name comparator.

- WidgetsAndShortcutNameComparator was using the actual widget and shortcut resolve
  infos as the key to the label cache.  Neither of these classes override hashCode()
  and we were retrieving a new set of widgets and shortcuts whenever packages changed
  so we would end up creating more and more entries in the cache.  This isn't a huge
  leak, but could lead to problems if Launcher is used for long periods without being
  killed.
- Now, we use a ComponentKey as the key, so that we don't keep a reference to the
  widget/shortcut infos and also ensures that they should hash to the same labels.

Change-Id: I91347ee72363adbc2b075b67dba331e35ab1fe34
parent a9095e07
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment