Added frame delete function for more interactivity.