summaryrefslogtreecommitdiff
path: root/src/wx/hints_dialog.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/wx/hints_dialog.cc')
-rw-r--r--src/wx/hints_dialog.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/wx/hints_dialog.cc b/src/wx/hints_dialog.cc
index 72ab0eef4..2150d4576 100644
--- a/src/wx/hints_dialog.cc
+++ b/src/wx/hints_dialog.cc
@@ -29,9 +29,11 @@
#include <wx/richtext/richtextctrl.h>
#include <boost/algorithm/string.hpp>
#include <boost/foreach.hpp>
+#include <boost/make_shared.hpp>
using std::max;
using boost::shared_ptr;
+using boost::make_shared;
using boost::optional;
using boost::dynamic_pointer_cast;
@@ -176,7 +178,7 @@ HintsDialog::film_changed ()
boost::filesystem::path path = film->audio_analysis_path (film->playlist ());
if (boost::filesystem::exists (path)) {
- shared_ptr<AudioAnalysis> an (new AudioAnalysis (path));
+ shared_ptr<AudioAnalysis> an = make_shared<AudioAnalysis> (path);
if (an->sample_peak() || an->true_peak()) {
float const peak = max (an->sample_peak().get_value_or(0), an->true_peak().get_value_or(0));
float const peak_dB = 20 * log10 (peak) + an->gain_correction (film->playlist ());