Use make_shared<>.
[dcpomatic.git] / src / wx / job_manager_view.cc
index cd6918b7268e730c7a93d4e8d1a796293c7cadf9..cba22178415473cbe9e9300c9452c10eb5800a50 100644 (file)
@@ -19,7 +19,7 @@
 */
 
 /** @file src/job_manager_view.cc
- *  @brief Class generating a GTK widget to show the progress of jobs.
+ *  @brief Class generating a widget to show the progress of jobs.
  */
 
 #include "job_manager_view.h"
@@ -30,6 +30,7 @@
 #include "lib/util.h"
 #include "lib/exceptions.h"
 #include "lib/compose.hpp"
+#include <boost/make_shared.hpp>
 #include <iostream>
 
 using std::string;
@@ -38,6 +39,7 @@ using std::map;
 using std::min;
 using std::cout;
 using boost::shared_ptr;
+using boost::make_shared;
 using boost::weak_ptr;
 
 /** Must be called in the GUI thread */
@@ -68,7 +70,7 @@ JobManagerView::job_added (weak_ptr<Job> j)
 {
        shared_ptr<Job> job = j.lock ();
        if (job) {
-               _job_records.push_back (shared_ptr<JobView> (new JobView (job, this, _panel, _table)));
+               _job_records.push_back (make_shared<JobView> (job, this, _panel, _table));
        }
 }