summaryrefslogtreecommitdiff
path: root/build-library.gradle
diff options
context:
space:
mode:
authorSailesh Nepal <sail@google.com>2016-04-13 15:01:39 -0700
committerUsman Abdullah <uabdullah@google.com>2016-04-20 18:32:47 +0000
commit4ceb430d354d76f18b293faf87a92854e26a94b8 (patch)
treeed94f602f61a698506ead57b6a2ebee70a5fa198 /build-library.gradle
parentd0db4f8941e13766b78c90432b92b4eaccf71e2c (diff)
Cache call type icons
Looking at the trace attached to b/28142787 it looks like CallTypeIconsView.Resources is created frequently. In my local testing with 9 items in my call log, it was created 23 times on load and 3 more times on scroll. According to the trace, creating a Resources object can be expensive. In one frame decodeBitmap was called 3 times and took 1.4 milliseconds. This CL works around the issue by caching the Resources object. This should be ok. The only downside of this is: - the cache won't be updated if the DPI variant changes - the cache won't be released if we get a memory pressure event Bug: 28142787 Change-Id: Ibc2ef02f7c92022deabedd70b1af135a10c9df29 (cherry picked from commit 341185547f9d54566055b270f69f1b93f0301c36)
Diffstat (limited to 'build-library.gradle')
0 files changed, 0 insertions, 0 deletions