projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Use bool literals for boolean values.
[pulseview.git]
/
pv
/
binding
/
device.hpp
diff --git
a/pv/binding/device.hpp
b/pv/binding/device.hpp
index 2a4c51634ed2ae734bc5b81a245054552822cde6..cd835f2993a4c246ed49b3e6a047eafd95f44eb1 100644
(file)
--- a/
pv/binding/device.hpp
+++ b/
pv/binding/device.hpp
@@
-14,12
+14,11
@@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ * along with this program; if not, see <http://www.gnu.org/licenses/>.
*/
*/
-#ifndef PULSEVIEW_PV_BINDING_DEVICE_H
-#define PULSEVIEW_PV_BINDING_DEVICE_H
+#ifndef PULSEVIEW_PV_BINDING_DEVICE_H
PP
+#define PULSEVIEW_PV_BINDING_DEVICE_H
PP
#include <boost/optional.hpp>
#include <boost/optional.hpp>
@@
-30,9
+29,12
@@
#include <pv/prop/property.hpp>
#include <pv/prop/property.hpp>
-namespace sigrok {
- class Configurable;
-}
+#include <libsigrokcxx/libsigrokcxx.hpp>
+
+using std::function;
+using std::pair;
+using std::set;
+using std::shared_ptr;
namespace pv {
namespace pv {
@@
-43,7
+45,7
@@
class Device : public QObject, public Binding
Q_OBJECT
public:
Q_OBJECT
public:
- Device(s
td::s
hared_ptr<sigrok::Configurable> configurable);
+ Device(shared_ptr<sigrok::Configurable> configurable);
Q_SIGNALS:
void config_changed();
Q_SIGNALS:
void config_changed();
@@
-51,22
+53,25
@@
Q_SIGNALS:
private:
void bind_bool(const QString &name,
prop::Property::Getter getter, prop::Property::Setter setter);
private:
void bind_bool(const QString &name,
prop::Property::Getter getter, prop::Property::Setter setter);
- void bind_enum(const QString &name, Glib::VariantContainerBase gvar_list,
+ void bind_enum(const QString &name,
+ const sigrok::ConfigKey *key,
+ set<const sigrok::Capability *> capabilities,
prop::Property::Getter getter, prop::Property::Setter setter,
prop::Property::Getter getter, prop::Property::Setter setter,
-
std::
function<QString (Glib::VariantBase)> printer = print_gvariant);
+ function<QString (Glib::VariantBase)> printer = print_gvariant);
void bind_int(const QString &name, QString suffix,
void bind_int(const QString &name, QString suffix,
- boost::optional<
std::
pair<int64_t, int64_t> > range,
+ boost::optional< pair<int64_t, int64_t> > range,
prop::Property::Getter getter, prop::Property::Setter setter);
static QString print_timebase(Glib::VariantBase gvar);
static QString print_vdiv(Glib::VariantBase gvar);
static QString print_voltage_threshold(Glib::VariantBase gvar);
prop::Property::Getter getter, prop::Property::Setter setter);
static QString print_timebase(Glib::VariantBase gvar);
static QString print_vdiv(Glib::VariantBase gvar);
static QString print_voltage_threshold(Glib::VariantBase gvar);
+ static QString print_probe_factor(Glib::VariantBase gvar);
protected:
protected:
- s
td::s
hared_ptr<sigrok::Configurable> configurable_;
+ shared_ptr<sigrok::Configurable> configurable_;
};
} // binding
} // pv
};
} // binding
} // pv
-#endif // PULSEVIEW_PV_BINDING_DEVICE_H
+#endif // PULSEVIEW_PV_BINDING_DEVICE_H
PP