From 3f9c971e761222dc9fb4e5866f81c5f7a3348992 Mon Sep 17 00:00:00 2001 From: Adam Cohen Date: Fri, 31 Oct 2014 11:48:25 -0700 Subject: Adding a couple memory optimizations to Launcher -> Always dispose of widget page views when leaving the activity. These pages hold onto many bitmaps. -> Clear database cache when leaving the activity. Bug: 17967108 Change-Id: I10ebaaed14e7cd86f09a9afcabd73043705f21b8 --- src/com/android/launcher3/AppsCustomizeTabHost.java | 8 -------- 1 file changed, 8 deletions(-) (limited to 'src/com/android/launcher3/AppsCustomizeTabHost.java') diff --git a/src/com/android/launcher3/AppsCustomizeTabHost.java b/src/com/android/launcher3/AppsCustomizeTabHost.java index 9a516fd41..df65cbaa1 100644 --- a/src/com/android/launcher3/AppsCustomizeTabHost.java +++ b/src/com/android/launcher3/AppsCustomizeTabHost.java @@ -141,14 +141,6 @@ public class AppsCustomizeTabHost extends FrameLayout implements LauncherTransit mPagedView.loadAssociatedPages(mPagedView.getCurrentPage()); } } - - public void onTrimMemory() { - mContent.setVisibility(GONE); - // Clear the widget pages of all their subviews - this will trigger the widget previews - // to delete their bitmaps - mPagedView.clearAllWidgetPages(); - } - @Override public ViewGroup getContent() { return mPagedView; -- cgit v1.2.3