Remove duplicate API to find session files (ignore ._ files)

Session::possible_states correctly filters files
and also directly returns sorted base-names.

We can remove the redundant `get_state_files_in_directory`
API now.

see also 193b35e885
This commit is contained in:
Robin Gareus 2023-06-07 17:37:40 +02:00
parent 04d50ab880
commit 91579608b2
No known key found for this signature in database
GPG key ID: A090BCE02CF57F04
3 changed files with 5 additions and 26 deletions

View file

@ -1109,9 +1109,7 @@ ARDOUR_UI::process_snapshot_session_prompter (Prompter& prompter, bool switch_to
}
}
vector<std::string> p;
get_state_files_in_directory (_session->session_directory().root_path(), p);
vector<string> n = get_file_names_no_extension (p);
vector<std::string> n = Session::possible_states (_session->session_directory().root_path());
if (find (n.begin(), n.end(), snapname) != n.end()) {