Moved region stuff into regions.c file.