How to create an intent to an activity depending on the flavor?
Hierarchy:
main
-ActivityA
flavor(free)
-uses main/ActivityA
flavor(paid)
-uses own paid/ActivityA
So how to create a Intent depending on the current flavor?
You can get Activity class by it's name. This way you won't get compile errors:
Intent i = new Intent(this, Class.forName("com.xxx.packagename.paid.ActivityA"))