Added UI context definition and creation/destruction.