cleaned up mobile drawing code