split custom flex programming into its own javascript file