Android spinning wheel (pizza) -


i trying create circle wheel divided in fixed number of sections. each section should clickable.

how approach this? should make image , set background or there way draw parts in java?

example

shortly:

create .png pizza.

create new widget, extending view.

override ondraw() , draw canvas rotation. optionally can draw lines java if it's margeritta not pepperoni.

if necessary - change rotation call invalidate() redraw view

add ontouch() listener, position ot tap, calculate sector touched.


Comments

Popular posts from this blog

jOOQ update returning clause with Oracle -

java - Warning equals/hashCode on @Data annotation lombok with inheritance -

java - BasicPathUsageException: Cannot join to attribute of basic type -