1# This is a configuration file for ProGuard. 2# http://proguard.sourceforge.net/index.html#manual/usage.html 3 4# Keep classes and methods that have the @VisibleForTesting annotation 5# TODO(b/373579455): Evaluate if <init> needs to be kept. 6-keep @com.android.internal.annotations.VisibleForTesting class * { 7 void <init>(); 8} 9-keepclassmembers class * { 10 @com.android.internal.annotations.VisibleForTesting *; 11} 12 13# We want to keep methods in Activity that could be used in the XML attribute onClick. 14-keepclassmembers class * extends android.app.Activity { 15 public void *(android.view.View); 16 public void *(android.view.MenuItem); 17} 18 19# Keep setters in Views so that animations can still work. 20-keep public class * extends android.view.View { 21 public <init>(android.content.Context); 22 public <init>(android.content.Context, android.util.AttributeSet); 23 public <init>(android.content.Context, android.util.AttributeSet, int); 24 25 void set*(***); 26 *** get*(); 27} 28 29# Keep classes that may be inflated from XML. 30-keepclasseswithmembers class * { 31 public <init>(android.content.Context, android.util.AttributeSet); 32} 33-keepclasseswithmembers class * { 34 public <init>(android.content.Context, android.util.AttributeSet, int); 35} 36 37# Keep annotated classes or class members. 38# TODO(b/373579455): Evaluate if <init> needs to be kept. 39-keep @androidx.annotation.Keep class * { 40 void <init>(); 41} 42-keepclassmembers class * { 43 @androidx.annotation.Keep *; 44} 45