More bug fixes

Removed a bug where the program prompted multiple times for saving
Removed a bug where StudyFrames had too many buttons and refused to work