From 9d049dc062df1c134105ec6a042aa9f56ae9c067 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Fri, 3 Jan 2020 02:29:24 +0100 Subject: [PATCH] Fix failure to save screen notes when making a new one (github bug #6). --- src/lib/screen.h | 7 ++++--- src/tools/dcpomatic_kdm_cli.cc | 2 +- src/wx/screens_panel.cc | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/lib/screen.h b/src/lib/screen.h index 829df2373..40990b684 100644 --- a/src/lib/screen.h +++ b/src/lib/screen.h @@ -1,5 +1,5 @@ /* - Copyright (C) 2013-2018 Carl Hetherington + Copyright (C) 2013-2019 Carl Hetherington This file is part of DCP-o-matic. @@ -58,8 +58,9 @@ namespace dcpomatic { class Screen { public: - Screen (std::string const & n, boost::optional rec, std::vector td) - : name (n) + Screen (std::string const & na, std::string const & no, boost::optional rec, std::vector td) + : name (na) + , notes (no) , recipient (rec) , trusted_devices (td) {} diff --git a/src/tools/dcpomatic_kdm_cli.cc b/src/tools/dcpomatic_kdm_cli.cc index e00e882a4..166b22285 100644 --- a/src/tools/dcpomatic_kdm_cli.cc +++ b/src/tools/dcpomatic_kdm_cli.cc @@ -508,7 +508,7 @@ int main (int argc, char* argv[]) { /* Make a new screen and add it to the current cinema */ dcp::CertificateChain chain (dcp::file_to_string(optarg)); - shared_ptr screen (new Screen (screen_description, chain.leaf(), vector())); + shared_ptr screen (new Screen (screen_description, "", chain.leaf(), vector())); if (cinema) { cinema->add_screen (screen); } diff --git a/src/wx/screens_panel.cc b/src/wx/screens_panel.cc index 7e012b522..8db7a1035 100644 --- a/src/wx/screens_panel.cc +++ b/src/wx/screens_panel.cc @@ -224,7 +224,7 @@ ScreensPanel::add_screen_clicked () } } - shared_ptr s (new Screen (d->name(), d->recipient(), d->trusted_devices())); + shared_ptr s (new Screen (d->name(), d->notes(), d->recipient(), d->trusted_devices())); c->add_screen (s); optional id = add_screen (c, s); if (id) { -- 2.30.2