X-Git-Url: http://git.code-monkey.de/?a=blobdiff_plain;f=pv%2Fpopups%2Fdeviceoptions.cpp;h=bdc0ab23ed48366353fc14c0b01daaa899d1fbdd;hb=8dbbc7f0b9ea59d0f0d62225772f8a56eee125f5;hp=c864865f4c854cea3ae96f8cec14286720c1cd35;hpb=51d4a9ab96a6bf64a1fcd1700e7e174498d4c118;p=pulseview.git diff --git a/pv/popups/deviceoptions.cpp b/pv/popups/deviceoptions.cpp index c864865..bdc0ab2 100644 --- a/pv/popups/deviceoptions.cpp +++ b/pv/popups/deviceoptions.cpp @@ -20,33 +20,34 @@ #include "deviceoptions.h" -#include - #include #include #include -using namespace boost; -using namespace std; +#include + +using std::shared_ptr; + +using sigrok::Device; namespace pv { namespace popups { -DeviceOptions::DeviceOptions(sr_dev_inst *sdi, QWidget *parent) : +DeviceOptions::DeviceOptions(shared_ptr device, QWidget *parent) : Popup(parent), - _sdi(sdi), - _layout(this), - _binding(sdi) + device_(device), + layout_(this), + binding_(device) { - setLayout(&_layout); + setLayout(&layout_); - _layout.addWidget(_binding.get_property_form(this)); + layout_.addWidget(binding_.get_property_form(this, true)); } -void DeviceOptions::closeEvent(QCloseEvent*) +pv::prop::binding::DeviceOptions& DeviceOptions::binding() { - _binding.commit(); + return binding_; } } // namespace popups