sudo.adam wrote: > Yes it is. I can't figure out whats going wrong. When I inflate it > by doing this in my main class in onCreate(): > > setContentView(R.layout.main); > > FrameLayout frame = (FrameLayout) findViewById(R.id.frame); > frame.addView(new TapPlotDrawer(this)); > > Its not a huge deal since this way works, but I'm curious about this > and I actually notice a slight performance difference when inflating > the XML and then adding as shown above.
Do you have a TapPlotDrawer(Context, AttributeSet) constructor? Here is a sample project showing a custom View class -- maybe it will give you some ideas: http://github.com/commonsguy/cw-advandroid/tree/master/Views/ColorMixer/ -- Mark Murphy (a Commons Guy) http://commonsware.com | http://twitter.com/commonsguy Android Training...At Your Office: http://commonsware.com/training -- 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

