move graphic.c from recovery to main tree