X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Ftools%2Fdcpomatic_kdm.cc;h=65326efb3e52139cfda31536c63b5f0bf02c3102;hb=c6871fe8617b3de03662b7630355059393bf8043;hp=b82cec2ad56d6b19a7097ec81930583f473a6bcf;hpb=4042c59cd8a1007e0d8f1959569bf2699bdfbe8b;p=dcpomatic.git diff --git a/src/tools/dcpomatic_kdm.cc b/src/tools/dcpomatic_kdm.cc index b82cec2ad..65326efb3 100644 --- a/src/tools/dcpomatic_kdm.cc +++ b/src/tools/dcpomatic_kdm.cc @@ -79,7 +79,7 @@ enum { class DOMFrame : public wxFrame { public: - DOMFrame (wxString const & title) + explicit DOMFrame (wxString const & title) : wxFrame (0, -1, title) , _config_dialog (0) , _job_view (0) @@ -328,7 +328,14 @@ private: } /* Encrypt */ - screen_kdms.push_back (ScreenKDM (i, kdm.encrypt (signer, i->recipient.get(), i->trusted_devices, _output->formulation()))); + screen_kdms.push_back ( + ScreenKDM ( + i, + kdm.encrypt ( + signer, i->recipient.get(), i->trusted_devices, _output->formulation(), true, 0 + ) + ) + ); } pair, int> result = _output->make ( @@ -356,7 +363,7 @@ private: } catch (dcp::NotEncryptedError& e) { error_dialog (this, _("CPL's content is not encrypted.")); } catch (exception& e) { - error_dialog (this, e.what ()); + error_dialog (this, std_to_wx(e.what())); } catch (...) { error_dialog (this, _("An unknown exception occurred.")); } @@ -423,10 +430,8 @@ private: } catch (dcp::KDMFormatError& e) { error_dialog ( this, - wxString::Format ( - _("Could not read file as a KDM. Perhaps it is badly formatted, or not a KDM at all.\n\n%s"), - std_to_wx(e.what()).data() - ) + _("Could not read file as a KDM. Perhaps it is badly formatted, or not a KDM at all."), + std_to_wx(e.what()) ); return; } catch (dcp::KDMDecryptionError) { @@ -603,7 +608,7 @@ private: } catch (exception& e) { - error_dialog (0, wxString::Format ("DCP-o-matic could not start: %s", e.what ())); + error_dialog (0, _("DCP-o-matic could not start"), std_to_wx(e.what())); return true; }