projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Replaced boost::function with std::function
[pulseview.git]
/
pv
/
toolbars
/
samplingbar.h
diff --git
a/pv/toolbars/samplingbar.h
b/pv/toolbars/samplingbar.h
index 454d607931be9633354549a43d89ba137c744024..2c2431c427a71ccb0fa3ff166b38503737d8edb9 100644
(file)
--- a/
pv/toolbars/samplingbar.h
+++ b/
pv/toolbars/samplingbar.h
@@
-25,8
+25,7
@@
#include <list>
#include <map>
#include <list>
#include <map>
-
-#include <boost/shared_ptr.hpp>
+#include <memory>
#include <QComboBox>
#include <QDoubleSpinBox>
#include <QComboBox>
#include <QDoubleSpinBox>
@@
-41,9
+40,12
@@
class QAction;
namespace pv {
namespace pv {
-class DevInst;
class SigSession;
class SigSession;
+namespace device {
+class DevInst;
+}
+
namespace toolbars {
class SamplingBar : public QToolBar
namespace toolbars {
class SamplingBar : public QToolBar
@@
-59,10
+61,11
@@
public:
SamplingBar(SigSession &session, QWidget *parent);
void set_device_list(
SamplingBar(SigSession &session, QWidget *parent);
void set_device_list(
- const std::list< boost::shared_ptr<pv::DevInst> > &devices);
+ const std::list< std::shared_ptr<pv::device::DevInst> >
+ &devices,
+ std::shared_ptr<pv::device::DevInst> selected);
- boost::shared_ptr<pv::DevInst> get_selected_device() const;
- void set_selected_device(boost::shared_ptr<pv::DevInst> dev_inst);
+ std::shared_ptr<pv::device::DevInst> get_selected_device() const;
void set_capture_state(pv::SigSession::capture_state state);
void set_capture_state(pv::SigSession::capture_state state);
@@
-73,6
+76,7
@@
private:
void update_sample_rate_selector();
void update_sample_rate_selector_value();
void update_sample_count_selector();
void update_sample_rate_selector();
void update_sample_rate_selector_value();
void update_sample_count_selector();
+ void update_device_config_widgets();
void commit_sample_rate();
void commit_sample_count();
void commit_sample_rate();
void commit_sample_count();
@@
-84,11
+88,14
@@
private slots:
void on_config_changed();
void on_config_changed();
+protected:
+ bool eventFilter(QObject *watched, QEvent *event);
+
private:
SigSession &_session;
QComboBox _device_selector;
private:
SigSession &_session;
QComboBox _device_selector;
- std::map<const sr_dev_inst*,
boost::weak_ptr<
DevInst> >
+ std::map<const sr_dev_inst*,
std::weak_ptr<device::
DevInst> >
_device_selector_map;
bool _updating_device_selector;
_device_selector_map;
bool _updating_device_selector;