summaryrefslogtreecommitdiff
path: root/src/wx/dir_picker_ctrl.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2023-01-16 01:14:37 +0100
committerCarl Hetherington <cth@carlh.net>2023-01-16 01:15:50 +0100
commitfe851f2e6e57d3a8781ecc173089c19632c521e3 (patch)
treefd0f388d9ce9eccb4a8011361bd166d192918bd8 /src/wx/dir_picker_ctrl.cc
parente8748f158249d7be906f6c6cf2411df45dd07a24 (diff)
Use wx_ptr more.
Diffstat (limited to 'src/wx/dir_picker_ctrl.cc')
-rw-r--r--src/wx/dir_picker_ctrl.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/wx/dir_picker_ctrl.cc b/src/wx/dir_picker_ctrl.cc
index 6c8fdd1fc..34e54532e 100644
--- a/src/wx/dir_picker_ctrl.cc
+++ b/src/wx/dir_picker_ctrl.cc
@@ -22,6 +22,7 @@
#include "dcpomatic_button.h"
#include "dir_picker_ctrl.h"
#include "static_text.h"
+#include "wx_ptr.h"
#include "wx_util.h"
#include <dcp/warnings.h>
LIBDCP_DISABLE_WARNINGS
@@ -83,9 +84,8 @@ DirPickerCtrl::GetPath () const
void
DirPickerCtrl::browse_clicked ()
{
- wxDirDialog* d = new wxDirDialog (this);
+ auto d = make_wx<wxDirDialog>(this);
if (d->ShowModal () == wxID_OK) {
SetPath (d->GetPath ());
}
- d->Destroy ();
}