summaryrefslogtreecommitdiff
path: root/src/wx/download_certificate_panel.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/wx/download_certificate_panel.cc')
-rw-r--r--src/wx/download_certificate_panel.cc14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/wx/download_certificate_panel.cc b/src/wx/download_certificate_panel.cc
index c30b05008..b3de4ca2c 100644
--- a/src/wx/download_certificate_panel.cc
+++ b/src/wx/download_certificate_panel.cc
@@ -58,10 +58,11 @@ DownloadCertificatePanel::DownloadCertificatePanel (DownloadCertificateDialog* d
optional<string>
-DownloadCertificatePanel::load_certificate (boost::filesystem::path file)
+DownloadCertificatePanel::load_certificate (boost::filesystem::path file, string url)
{
try {
_certificate = dcp::Certificate (dcp::file_to_string(file));
+ _url = url;
} catch (dcp::MiscError& e) {
return String::compose(wx_to_std(_("Could not read certificate file (%1)")), e.what());
}
@@ -70,10 +71,11 @@ DownloadCertificatePanel::load_certificate (boost::filesystem::path file)
optional<string>
-DownloadCertificatePanel::load_certificate_from_chain (boost::filesystem::path file)
+DownloadCertificatePanel::load_certificate_from_chain (boost::filesystem::path file, string url)
{
try {
_certificate = dcp::CertificateChain (dcp::file_to_string(file)).leaf();
+ _url = url;
} catch (dcp::MiscError& e) {
return String::compose(wx_to_std(_("Could not read certificate file (%1)")), e.what());
}
@@ -88,6 +90,14 @@ DownloadCertificatePanel::certificate () const
}
+
+optional<string>
+DownloadCertificatePanel::url () const
+{
+ return _url;
+
+}
+
void
DownloadCertificatePanel::download ()
{