*/
#include <cassert>
-#include <sstream>
#include <QDebug>
#include "devinst.h"
-using std::ostringstream;
-using std::string;
-
namespace pv {
namespace device {
return _sdi;
}
-string DevInst::format_device_title() const
-{
- ostringstream s;
-
- assert(_sdi);
-
- if (_sdi->vendor && _sdi->vendor[0]) {
- s << _sdi->vendor;
- if ((_sdi->model && _sdi->model[0]) ||
- (_sdi->version && _sdi->version[0]))
- s << ' ';
- }
-
- if (_sdi->model && _sdi->model[0]) {
- s << _sdi->model;
- if (_sdi->version && _sdi->version[0])
- s << ' ';
- }
-
- if (_sdi->version && _sdi->version[0])
- s << _sdi->version;
-
- return s.str();
-}
-
GVariant* DevInst::get_config(const sr_probe_group *group, int key)
{
GVariant *data = NULL;