I need to draw something on the same canvas that onDraw() get access to.
This works fine as long as I am inside OnDraw(), but I don’t know how to get that canvas when I’m outside.
Thanks for any suggestions.
@Override
protected void onDraw(Canvas canvas) {
canvas.doSomething // works fine
}
//new method to draw omething on the same canvas
mydraw(how to get canvas in here?){}
You can try to send canvas to your own method: