Cg_Forms module refactoring