Я пытаюсь создать свой собственный вид и пытаюсь добавить в него кнопки или TextViews.
public class Test extends View{
Button _button;
public Test(Context context) {
super(context);
_button = new Button(getContext());
}
@Override
protected void onDraw(final Canvas canvas)
{
super.dispatchDraw(canvas);
canvas.drawBitmap(BitmapFactory.decodeResource(getContext().getResources(), R.drawable.ic_launcher), 100, 100, new Paint());
}
}
Так как показать эту кнопку на холсте, как этот растровый рисунок?
Спасибо.