projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix bug #285 by handling device display names through DeviceManager
[pulseview.git]
/
pv
/
devicemanager.h
diff --git
a/pv/devicemanager.h
b/pv/devicemanager.h
index 0a47a35a004659b09da56ce7545135159a448939..511ba76091083679bdf96b021a6c4f312e12b5a2 100644
(file)
--- a/
pv/devicemanager.h
+++ b/
pv/devicemanager.h
@@
-64,15
+64,20
@@
public:
const std::shared_ptr<sigrok::HardwareDevice> find_device_from_info(
const std::map<std::string, std::string> search_info);
const std::shared_ptr<sigrok::HardwareDevice> find_device_from_info(
const std::map<std::string, std::string> search_info);
- static std::string device_description(std::shared_ptr<sigrok::Device> device);
+ const std::string build_display_name(std::shared_ptr<sigrok::Device> device);
+
+ const std::string get_display_name(std::shared_ptr<sigrok::Device> dev);
+
+ void update_display_name(std::shared_ptr<sigrok::Device> dev);
private:
private:
-
static bool compare_devices(std::shared_ptr<sigrok::Hardware
Device> a,
- std::shared_ptr<sigrok::
Hardware
Device> b);
+
bool compare_devices(std::shared_ptr<sigrok::
Device> a,
+ std::shared_ptr<sigrok::Device> b);
protected:
std::shared_ptr<sigrok::Context> _context;
std::list< std::shared_ptr<sigrok::HardwareDevice> > _devices;
protected:
std::shared_ptr<sigrok::Context> _context;
std::list< std::shared_ptr<sigrok::HardwareDevice> > _devices;
+ std::map< std::shared_ptr<sigrok::Device>, std::string > _display_names;
};
} // namespace pv
};
} // namespace pv