diff options
| author | Carl Hetherington <cth@carlh.net> | 2024-06-28 00:40:52 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2024-06-28 00:40:52 +0200 |
| commit | 642b1a42643abdb67106b8a9d6ac74a647be3c45 (patch) | |
| tree | 634e80fce49edc04f344cdd037bf1df852e13b6f | |
| parent | f1c252ed862e87f26eb3f68c7478e4a7cd682272 (diff) | |
Add some wxYield()s.certs
One or more of these improve GUI responsiveness when downloading
certificates and make it less likely that GNOME complains that
DCP-o-matic has hung.
| -rw-r--r-- | src/wx/dolby_doremi_certificate_panel.cc | 2 | ||||
| -rw-r--r-- | src/wx/download_certificate_panel.cc | 1 |
2 files changed, 3 insertions, 0 deletions
diff --git a/src/wx/dolby_doremi_certificate_panel.cc b/src/wx/dolby_doremi_certificate_panel.cc index 7f1139753..5a695ca75 100644 --- a/src/wx/dolby_doremi_certificate_panel.cc +++ b/src/wx/dolby_doremi_certificate_panel.cc @@ -196,6 +196,7 @@ DolbyDoremiCertificatePanel::do_download () if (starts_with_digit) { try_common(locations, prefix, serial); + wxYield(); try_cat862(locations, prefix, serial); try_dsp100(locations, prefix, serial); } else if (starting_char == 'H') { @@ -209,6 +210,7 @@ DolbyDoremiCertificatePanel::do_download () bool ok = false; auto location = locations.begin(); while (!ok && location != locations.end()) { + wxYield(); auto error = get_from_zip_url(location->url, location->file, true, true, boost::bind(&DownloadCertificatePanel::load_certificate, this, _1, _2)); ++location; if (error) { diff --git a/src/wx/download_certificate_panel.cc b/src/wx/download_certificate_panel.cc index 3f1509f60..f3721fec6 100644 --- a/src/wx/download_certificate_panel.cc +++ b/src/wx/download_certificate_panel.cc @@ -105,6 +105,7 @@ DownloadCertificatePanel::download () /* Hack: without this the SetLabel() above has no visible effect */ wxMilliSleep (200); + wxYield(); signal_manager->when_idle (boost::bind(&DownloadCertificatePanel::do_download, this)); } |
