diff options
| author | Carl Hetherington <cth@carlh.net> | 2024-05-09 21:33:19 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2024-05-25 01:30:31 +0200 |
| commit | 00706c7d9ded27a537af4e8182e67b460ec316bc (patch) | |
| tree | d865f043808a0f839495b8e80c1c9694835d7a44 | |
| parent | e38123db163b3a9722b0a82af813fb2e4fa41e76 (diff) | |
Use std::vector for Config::templates().
| -rw-r--r-- | src/lib/config.cc | 4 | ||||
| -rw-r--r-- | src/lib/config.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/lib/config.cc b/src/lib/config.cc index 374605521..879c29279 100644 --- a/src/lib/config.cc +++ b/src/lib/config.cc @@ -1391,14 +1391,14 @@ Config::save_template (shared_ptr<const Film> film, string name) const } -list<string> +vector<string> Config::templates () const { if (!dcp::filesystem::exists(read_path("templates"))) { return {}; } - list<string> n; + vector<string> n; for (auto const& i: dcp::filesystem::directory_iterator(read_path("templates"))) { n.push_back (i.path().filename().string()); } diff --git a/src/lib/config.h b/src/lib/config.h index b62c38116..1a59f4bad 100644 --- a/src/lib/config.h +++ b/src/lib/config.h @@ -1270,7 +1270,7 @@ public: void save_template (std::shared_ptr<const Film> film, std::string name) const; bool existing_template (std::string name) const; - std::list<std::string> templates () const; + std::vector<std::string> templates() const; boost::filesystem::path template_read_path (std::string name) const; void rename_template (std::string old_name, std::string new_name) const; void delete_template (std::string name) const; |
