summaryrefslogtreecommitdiff
path: root/src/tools/dcpomatic.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2025-02-09 02:06:04 +0100
committerCarl Hetherington <cth@carlh.net>2025-02-09 17:29:16 +0100
commitd0308d53dd9f4d036d8c5fe8023920fcdfd43f39 (patch)
tree5b37c1db5dc50e541a542663390061f743fe815a /src/tools/dcpomatic.cc
parent8d0d9866ae3e0395d899705e27b3806a5de7ef0e (diff)
Remove unnecessary wx_ptr
It was only ever used for wxDialog subclasses, which can be stack-allocated.
Diffstat (limited to 'src/tools/dcpomatic.cc')
-rw-r--r--src/tools/dcpomatic.cc16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/tools/dcpomatic.cc b/src/tools/dcpomatic.cc
index 3d9d571af..7048781e3 100644
--- a/src/tools/dcpomatic.cc
+++ b/src/tools/dcpomatic.cc
@@ -876,7 +876,7 @@ private:
return;
}
- _kdm_dialog.reset(this, _film);
+ _kdm_dialog.emplace(this, _film);
_kdm_dialog->Show ();
}
@@ -886,7 +886,7 @@ private:
return;
}
- _dkdm_dialog.reset(this, _film);
+ _dkdm_dialog.emplace(this, _film);
_dkdm_dialog->Show ();
}
@@ -1083,7 +1083,7 @@ private:
void view_video_waveform ()
{
if (!_video_waveform_dialog) {
- _video_waveform_dialog.reset(this, _film, _film_viewer);
+ _video_waveform_dialog.emplace(this, _film, _film_viewer);
}
_video_waveform_dialog->Show ();
@@ -1130,7 +1130,7 @@ private:
void tools_manage_templates ()
{
if (!_templates_dialog) {
- _templates_dialog.reset(this);
+ _templates_dialog.emplace(this);
}
_templates_dialog->Show ();
@@ -1578,15 +1578,15 @@ private:
wxPanel* _right_panel;
FilmViewer _film_viewer;
StandardControls* _controls;
- wx_ptr<VideoWaveformDialog> _video_waveform_dialog;
+ boost::optional<VideoWaveformDialog> _video_waveform_dialog;
SystemInformationDialog* _system_information_dialog = nullptr;
DCPReferencingDialog* _dcp_referencing_dialog = nullptr;
HintsDialog* _hints_dialog = nullptr;
ServersListDialog* _servers_list_dialog = nullptr;
wxPreferencesEditor* _config_dialog = nullptr;
- wx_ptr<KDMDialog> _kdm_dialog;
- wx_ptr<DKDMDialog> _dkdm_dialog;
- wx_ptr<TemplatesDialog> _templates_dialog;
+ boost::optional<KDMDialog> _kdm_dialog;
+ boost::optional<DKDMDialog> _dkdm_dialog;
+ boost::optional<TemplatesDialog> _templates_dialog;
wxMenu* _file_menu = nullptr;
shared_ptr<Film> _film;
int _history_items = 0;