]> sigrok.org Git - pulseview.git/blobdiff - pv/toolbars/samplingbar.cpp
Replaced boost::shared_ptr with std::shared_ptr
[pulseview.git] / pv / toolbars / samplingbar.cpp
index 085e0430582e08b5ff488b7b1d2a708ef35bca35..af5afb0c27774b980ae843c68e73a81b6e135217 100644 (file)
@@ -22,8 +22,6 @@
 
 #include <assert.h>
 
-#include <boost/foreach.hpp>
-
 #include <QAction>
 #include <QDebug>
 #include <QHelpEvent>
 #include <pv/popups/probes.h>
 #include <pv/util.h>
 
-using boost::shared_ptr;
 using std::map;
 using std::max;
 using std::min;
+using std::shared_ptr;
 using std::string;
 
 namespace pv {
@@ -114,7 +112,7 @@ void SamplingBar::set_device_list(
        _device_selector.clear();
        _device_selector_map.clear();
 
-       BOOST_FOREACH (shared_ptr<pv::device::DevInst> dev_inst, devices) {
+       for (shared_ptr<pv::device::DevInst> dev_inst : devices) {
                assert(dev_inst);
                const string title = dev_inst->format_device_title();
                const sr_dev_inst *sdi = dev_inst->dev_inst();
@@ -148,8 +146,7 @@ shared_ptr<pv::device::DevInst> SamplingBar::get_selected_device() const
                        index).value<void*>();
        assert(sdi);
 
-       map<const sr_dev_inst*, boost::weak_ptr<device::DevInst> >::
-               const_iterator iter = _device_selector_map.find(sdi);
+       const auto iter = _device_selector_map.find(sdi);
        if (iter == _device_selector_map.end())
                return shared_ptr<pv::device::DevInst>();