mv widgets function to its own file