OK, how about this related issue?
I wrote a utility class that I want to use in multiple products.
org.efalk.gridbox.GridBox <= my utility class
org.efalk.rpncalc.RpnCalc <= product that I want to use Gridbox
The Gridbox class looks like:
package org.efalk.gridbox;
...
private void GridboxInit(Context ctx, AttributeSet attrs)
{
if( attrs != null ) {
TypedArray a = ctx.obtainStyledAttributes(attrs,
R.styleable.Gridbox);
innerMargin =
a.getDimensionPixelSize(R.styleable.Gridbox_inner_margin,
innerMargin);
gravity = a.getInt(R.styleable.Gridbox_gravity, gravity);
}
}
This code fails to compile with "R cannot be resolved"
How can I get R to resolve? I can make it all work by moving my
GridBox class into the same directory as my main program and renaming
everything appropriately, but that defeats the purpose of having a
single .java file which I can use in more than one application.
Are there any examples out there of somebody creating a custom View
class and putting it into a different directory from R.java?
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en