projects
/
pulseview.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
TraceTreeItemOwner: Moved list_by_type template definition into header
[pulseview.git]
/
pv
/
view
/
tracetreeitemowner.hpp
diff --git
a/pv/view/tracetreeitemowner.hpp
b/pv/view/tracetreeitemowner.hpp
index 905746d6c5f956ab2787886efcb4b14ccfeea5a1..4c0043f66dd9b7b51bad1e188fe7d30297e9ed59 100644
(file)
--- a/
pv/view/tracetreeitemowner.hpp
+++ b/
pv/view/tracetreeitemowner.hpp
@@
-128,7
+128,16
@@
public:
* Creates a list of decendant signals filtered by type.
*/
template<class T>
* Creates a list of decendant signals filtered by type.
*/
template<class T>
- std::set< std::shared_ptr<T> > list_by_type();
+ std::set< std::shared_ptr<T> > list_by_type() {
+ std::set< std::shared_ptr<T> > items;
+ for (const auto &r : *this) {
+ std::shared_ptr<T> p = std::dynamic_pointer_cast<T>(r);
+ if (p)
+ items.insert(p);
+ }
+
+ return items;
+ }
/**
* Computes the vertical extents of the contents of this row item owner.
/**
* Computes the vertical extents of the contents of this row item owner.