Added fail-safe checks for get_current_folder() calls with gtk.FileChooserDialog instances