Skip to content Skip to sidebar Skip to footer

Proguard Does Not Obfuscate Gui Components

I would like to use ProGuard to obfuscate my Android app. This works fine. But my gui classes, which extends acitvity, view and sherlockactivity are not obfuscated. Here is the pro

Solution 1:

But my gui classes, which extends acitvit, view and sherlockactivtiy are not obfusecated.

That is because your ProGuard configuration file says to not obfuscate them. Moreover, this is important, as if they are obfuscated, your app will not run, because:

  • Android will not find your renamed activities
  • Android will not find your activity lifecycle methods
  • Android will not find your widgets (for use with reflection in interpreting layout resources)
  • etc.

I´ve tried to added: -keep public class mypackege.myactivity.class But it does not solve the problem.

That is because you are telling ProGuard to not obfuscate that class.

Any ideas how to obfusecate the gui elements?

You don't, if you wish to have a working app when you are done.

Post a Comment for "Proguard Does Not Obfuscate Gui Components"