diff options
| author | Carl Hetherington <cth@carlh.net> | 2023-11-11 22:19:37 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2023-11-11 22:19:37 +0100 |
| commit | e631609fae5ea0ac452c98a4a8623996df37e4be (patch) | |
| tree | b34c212a17d92deb831bac434f4849086487b201 /src/wx/content_menu.cc | |
| parent | 3b687bd8656af6ac9c65db2dbd37ddd4a3bc97f4 (diff) | |
Cleanup: stack-allocated dialogs.
Diffstat (limited to 'src/wx/content_menu.cc')
| -rw-r--r-- | src/wx/content_menu.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wx/content_menu.cc b/src/wx/content_menu.cc index 73591eaed..5d9865970 100644 --- a/src/wx/content_menu.cc +++ b/src/wx/content_menu.cc @@ -402,15 +402,15 @@ ContentMenu::kdm () auto dcp = dynamic_pointer_cast<DCPContent> (_content.front()); DCPOMATIC_ASSERT (dcp); - auto d = make_wx<wxFileDialog>(_parent, _("Select KDM")); + wxFileDialog dialog(_parent, _("Select KDM")); - if (d->ShowModal() != wxID_OK) { + if (dialog.ShowModal() != wxID_OK) { return; } optional<dcp::EncryptedKDM> kdm; try { - kdm = dcp::EncryptedKDM (dcp::file_to_string(wx_to_std(d->GetPath()), MAX_KDM_SIZE)); + kdm = dcp::EncryptedKDM(dcp::file_to_string(wx_to_std(dialog.GetPath()), MAX_KDM_SIZE)); } catch (exception& e) { error_dialog (_parent, _("Could not load KDM"), std_to_wx(e.what())); return; |
