diff options
author | Adam Cohen <adamcohen@google.com> | 2015-03-18 14:16:05 -0700 |
---|---|---|
committer | Adam Cohen <adamcohen@google.com> | 2015-03-20 11:15:54 -0700 |
commit | 091440a9cb9d4f42406631004aa484cbb79214ca (patch) | |
tree | 828aaa4033c73fe84a2e7e567c9cc4909c5a014f /src/com/android/launcher3/LauncherClings.java | |
parent | f846b9054c90e73cb824310e75ea904b5a459c01 (diff) | |
download | android_packages_apps_Trebuchet-091440a9cb9d4f42406631004aa484cbb79214ca.tar.gz android_packages_apps_Trebuchet-091440a9cb9d4f42406631004aa484cbb79214ca.tar.bz2 android_packages_apps_Trebuchet-091440a9cb9d4f42406631004aa484cbb79214ca.zip |
Reducing method count by eliminating synthetic accessors
Elimates 304 methods based on dex analysis
The java compiler generates sythetic accessor methods for all private
fields, methods and contructors accessed from inner classes. By marking them
package-private and @Thunk instead, sythentic accessor methods are no
longer needeed. These annotated elements should be treated as private.
Change-Id: Id0dc2c92733474250d8ff12fa793d3a8adeb1f26
Diffstat (limited to 'src/com/android/launcher3/LauncherClings.java')
-rw-r--r-- | src/com/android/launcher3/LauncherClings.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/com/android/launcher3/LauncherClings.java b/src/com/android/launcher3/LauncherClings.java index ef8e8abcf..2ce8b1c59 100644 --- a/src/com/android/launcher3/LauncherClings.java +++ b/src/com/android/launcher3/LauncherClings.java @@ -35,6 +35,8 @@ import android.view.ViewGroup; import android.view.ViewTreeObserver.OnGlobalLayoutListener; import android.view.accessibility.AccessibilityManager; +import com.android.launcher3.util.Thunk; + class LauncherClings implements OnClickListener { private static final String MIGRATION_CLING_DISMISSED_KEY = "cling_gel.migration.dismissed"; private static final String WORKSPACE_CLING_DISMISSED_KEY = "cling_gel.workspace.dismissed"; @@ -49,7 +51,7 @@ class LauncherClings implements OnClickListener { // New Secure Setting in L private static final String SKIP_FIRST_USE_HINTS = "skip_first_use_hints"; - private Launcher mLauncher; + @Thunk Launcher mLauncher; private LayoutInflater mInflater; /** Ctor */ @@ -174,7 +176,7 @@ class LauncherClings implements OnClickListener { }); } - private void dismissLongPressCling() { + @Thunk void dismissLongPressCling() { Runnable dismissCb = new Runnable() { public void run() { dismissCling(mLauncher.findViewById(R.id.longpress_cling), null, @@ -185,7 +187,7 @@ class LauncherClings implements OnClickListener { } /** Hides the specified Cling */ - private void dismissCling(final View cling, final Runnable postAnimationCb, + @Thunk void dismissCling(final View cling, final Runnable postAnimationCb, final String flag, int duration) { // To catch cases where siblings of top-level views are made invisible, just check whether // the cling is directly set to GONE before dismissing it. |