sdelmont
1p1 comments posted · 0 followers · following 0
16 years ago @ Mea Cup O' Jo - Android - how to deplo... · 0 replies · +1 points
I was going down the same route of using a "sub-package name" for different releases, and ran into the same issue with the R class.
My fix was to add an R.java file at the com.foo.widget level, copy the contents of the generated com.foo.widget.free.R.java file and change the package name.
The only inconvenience is that whenever I add a new resource, the Eclipse plugin updates the generated file automatically, but I have to remember to copy the contents again.
Still, it's way easier this way, since resources are not changed that often, and if you forget to copy the generated changes, you get a compiler error (most of the time).
My fix was to add an R.java file at the com.foo.widget level, copy the contents of the generated com.foo.widget.free.R.java file and change the package name.
The only inconvenience is that whenever I add a new resource, the Eclipse plugin updates the generated file automatically, but I have to remember to copy the contents again.
Still, it's way easier this way, since resources are not changed that often, and if you forget to copy the generated changes, you get a compiler error (most of the time).