diff options
| author | Carl Hetherington <cth@carlh.net> | 2023-05-18 22:21:33 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2023-05-18 22:21:33 +0200 |
| commit | 9f125fddff88bf62d36381f9d3f09e5240b033d5 (patch) | |
| tree | 586e3040791a634f58e3c0d04e7550490af732f6 /src/wx/cinema_dialog.cc | |
| parent | c407bf65787162ea712595eecf9fbb409c7f0d1e (diff) | |
Cleanup: replace some list with vector.
Diffstat (limited to 'src/wx/cinema_dialog.cc')
| -rw-r--r-- | src/wx/cinema_dialog.cc | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/src/wx/cinema_dialog.cc b/src/wx/cinema_dialog.cc index 8c7194c4a..84fde5f41 100644 --- a/src/wx/cinema_dialog.cc +++ b/src/wx/cinema_dialog.cc @@ -28,7 +28,6 @@ using std::back_inserter; using std::copy; using std::cout; -using std::list; using std::string; using std::vector; using boost::bind; @@ -37,7 +36,7 @@ using namespace boost::placeholders; #endif -CinemaDialog::CinemaDialog (wxWindow* parent, wxString title, string name, list<string> emails, string notes, int utc_offset_hour, int utc_offset_minute) +CinemaDialog::CinemaDialog(wxWindow* parent, wxString title, string name, vector<string> emails, string notes, int utc_offset_hour, int utc_offset_minute) : wxDialog (parent, wxID_ANY, title) { auto overall_sizer = new wxBoxSizer (wxVERTICAL); @@ -69,7 +68,7 @@ CinemaDialog::CinemaDialog (wxWindow* parent, wxString title, string name, list< vector<EditableListColumn> columns; columns.push_back (EditableListColumn(_("Address"), 500, true)); _email_list = new EditableList<string, EmailDialog> ( - this, columns, bind (&CinemaDialog::get_emails, this), bind (&CinemaDialog::set_emails, this, _1), [](string s, int) { + this, columns, bind(&CinemaDialog::emails, this), bind (&CinemaDialog::set_emails, this, _1), [](string s, int) { return s; }, EditableListTitle::INVISIBLE, EditableListButton::NEW | EditableListButton::EDIT | EditableListButton::REMOVE ); @@ -117,21 +116,12 @@ CinemaDialog::set_emails (vector<string> e) vector<string> -CinemaDialog::get_emails () const +CinemaDialog::emails() const { return _emails; } -list<string> -CinemaDialog::emails () const -{ - list<string> e; - copy (_emails.begin(), _emails.end(), back_inserter(e)); - return e; -} - - int CinemaDialog::utc_offset_hour () const { |
