Fix for deleting the file that is currently selected

Due to a missing switch to a refactored version of an internal data structure, that file stayed being selected but wasn't actually there anymore, leading to an error upon hitting Print.