Moves some UI code in the UI module.