Update main.c

Graphic primitives and buttons management