From 6d770c4c8c79569871edc20253f29f9ea00539e6 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Fri, 9 Mar 2018 00:55:49 +0000 Subject: Check for signer chains containing UTF8-marked strings and offer to fix them on startup (#1218). --- src/tools/dcpomatic.cc | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'src/tools') diff --git a/src/tools/dcpomatic.cc b/src/tools/dcpomatic.cc index b22120143..1e6c49d7b 100644 --- a/src/tools/dcpomatic.cc +++ b/src/tools/dcpomatic.cc @@ -29,6 +29,7 @@ #include "wx/wx_util.h" #include "wx/film_name_location_dialog.h" #include "wx/wx_signal_manager.h" +#include "wx/recreate_chain_dialog.h" #include "wx/about_dialog.h" #include "wx/kdm_dialog.h" #include "wx/self_dkdm_dialog.h" @@ -1281,6 +1282,8 @@ private: */ Config::drop (); + Config::BadSignerChain.connect (boost::bind (&App::config_bad_signer_chain, this)); + _frame = new DOMFrame (_("DCP-o-matic")); SetTopWindow (_frame); _frame->Maximize (); @@ -1420,6 +1423,18 @@ private: message_dialog (_frame, std_to_wx (m)); } + bool config_bad_signer_chain () + { + if (Config::instance()->nagged(Config::NAG_BAD_SIGNER_CHAIN)) { + return false; + } + + RecreateChainDialog* d = new RecreateChainDialog (_frame); + int const r = d->ShowModal (); + d->Destroy (); + return r == wxID_OK; + } + DOMFrame* _frame; shared_ptr _timer; string _film_to_load; -- cgit v1.2.3