blob: 21c5cfda9cd2bc367382e2518abe4488f198cfe6 [file] [log] [blame]
Justin Klaassend770c052016-06-28 19:26:43 -07001# This is a configuration file for ProGuard.
2# http://proguard.sourceforge.net/index.html#manual/usage.html
3
Daisuke Miyakawac81adf52010-08-12 13:04:43 -07004# Keep all Fragments in this package, which are used by reflection.
Justin Klaassen478b5a82016-06-21 18:31:16 -07005-keep public class com.android.settings.** extends android.app.Fragment
Amith Yamasanib14e1e02010-11-02 09:52:29 -07006
Fan Zhang917f1012018-02-21 15:22:25 -08007# Keep all preference controllers needed by slice and DashboardFragment.
8-keep class * extends com.android.settings.core.BasePreferenceController {
9 *;
10}
11
12-keep class * extends com.android.settings.core.TogglePreferenceController {
13 *;
14}
15
Justin Klaassend770c052016-06-28 19:26:43 -070016# We want to keep methods in Activity that could be used in the XML attribute onClick.
Justin Klaassen478b5a82016-06-21 18:31:16 -070017-keepclassmembers class * extends android.app.Activity {
Justin Klaassenab704112016-08-01 16:16:40 -070018 public void *(android.view.View);
19 public void *(android.view.MenuItem);
Jean Chalard0824d312011-12-02 17:47:09 +090020}
Udam Saini8ef4c622016-02-03 17:31:11 -080021
Justin Klaassend770c052016-06-28 19:26:43 -070022# Keep setters in Views so that animations can still work.
23-keep public class * extends android.view.View {
24 public <init>(android.content.Context);
25 public <init>(android.content.Context, android.util.AttributeSet);
26 public <init>(android.content.Context, android.util.AttributeSet, int);
27
28 void set*(***);
29 *** get*();
30}
31
32# Keep classes that may be inflated from XML.
Justin Klaassen478b5a82016-06-21 18:31:16 -070033-keepclasseswithmembers class * {
Udam Saini8ef4c622016-02-03 17:31:11 -080034 public <init>(android.content.Context, android.util.AttributeSet);
Justin Klaassend770c052016-06-28 19:26:43 -070035}
36-keepclasseswithmembers class * {
Justin Klaassen478b5a82016-06-21 18:31:16 -070037 public <init>(android.content.Context, android.util.AttributeSet, int);
Anna Galusza16d58e72016-03-22 13:07:44 -070038}
Matthew Fritzeb2775572017-12-05 10:46:47 -080039-keepclasseswithmembers class * {
40 public <init>(android.content.Context, android.util.AttributeSet, int, int);
41}
Justin Klaassenab704112016-08-01 16:16:40 -070042
43# Keep annotated classes or class members.
44-keep @android.support.annotation.Keep class *
45-keepclassmembers class * {
46 @android.support.annotation.Keep *;
47}
48
49# Keep specific fields used via reflection.
50-keepclassmembers class * {
51 public static ** SEARCH_INDEX_DATA_PROVIDER;
52 public static ** SUMMARY_PROVIDER_FACTORY;
53}