Advertisement
Guest User

Untitled

a guest
Aug 20th, 2014
168
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.59 KB | None | 0 0
  1. public class AvatarView extends ImageView {
  2.  
  3. public AvatarView(Context context) {
  4. super(context);
  5. }
  6.  
  7. public AvatarView(Context context, AttributeSet attrs) {
  8. super(context, attrs);
  9. }
  10.  
  11. public AvatarView(Context context, AttributeSet attrs, int defStyle) {
  12. super(context, attrs, defStyle);
  13. }
  14.  
  15. @Override
  16. protected void onDraw(Canvas canvas) {
  17. super.onDraw(canvas);
  18. canvas.drawBitmap(BitmapFactory.decodeResource(getResources(), R.drawable.battle_run_char), 0, 70, null);
  19. canvas.drawBitmap(BitmapFactory.decodeResource(getResources(), R.drawable.red_cartoon_hat), 70, 0, null);
  20. }
  21.  
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement