From b0bc20e5fc4cc02a99b1666363f8a2a3937f2b3b Mon Sep 17 00:00:00 2001 From: Dave Mankoff Date: Thu, 18 Nov 2021 20:37:53 -0500 Subject: [PATCH] Prune proguard.flags down to more essential pieces. At first measure, this saves approximately 125KB on SystemUIGoogle. More importantly, it opens the door for more savings as code is further refactored. Bug: 205725937 Test: manual Change-Id: Id9566fb30a7e2436f3f55c12705ba27b9c89bcac --- packages/SystemUI/proguard.flags | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/packages/SystemUI/proguard.flags b/packages/SystemUI/proguard.flags index 6352f81b44745..cf6951233e237 100644 --- a/packages/SystemUI/proguard.flags +++ b/packages/SystemUI/proguard.flags @@ -1,22 +1,16 @@ # Preserve line number information for debugging stack traces. -keepattributes SourceFile,LineNumberTable --keep class com.android.systemui.recents.OverviewProxyRecentsImpl --keep class com.android.systemui.statusbar.car.CarStatusBar --keep class com.android.systemui.statusbar.phone.StatusBar --keep class com.android.systemui.statusbar.tv.TvStatusBar -keep class com.android.systemui.car.CarSystemUIFactory -keep class com.android.systemui.SystemUIFactory -keep class com.android.systemui.tv.TvSystemUIFactory --keep class * extends com.android.systemui.CoreStartable --keep class * implements com.android.systemui.CoreStartable$Injector -keepclasseswithmembers class * { public (android.content.Context, android.util.AttributeSet); } -keep class ** extends androidx.preference.PreferenceFragment --keep class com.android.systemui.tuner.* + -keep class com.android.systemui.plugins.** { *; } @@ -25,10 +19,6 @@ } -keep class androidx.core.app.CoreComponentFactory --keep public class * extends com.android.systemui.CoreStartable { - public (android.content.Context); -} - # Keep the wm shell lib -keep class com.android.wm.shell.* # Keep the protolog group methods that are called by the generated code @@ -36,11 +26,6 @@ *; } --keep,allowoptimization,allowaccessmodification class com.android.systemui.dagger.GlobalRootComponent { !synthetic *; } --keep,allowoptimization,allowaccessmodification class com.android.systemui.dagger.GlobalRootComponent$SysUIComponentImpl { !synthetic *; } --keep,allowoptimization,allowaccessmodification class com.android.systemui.dagger.Dagger** { !synthetic *; } --keep,allowoptimization,allowaccessmodification class com.android.systemui.tv.Dagger** { !synthetic *; } - # Allows proguard to make private and protected methods and fields public as # part of optimization. This lets proguard inline trivial getter/setter methods. -allowaccessmodification