Changed the returnToLibraryView function to close any open viewImage
windows.