#include <cmath>
#include <iostream>
#include <iterator>
-#include <unordered_set>
#include <QApplication>
#include <QDebug>
using std::set;
using std::set_difference;
using std::shared_ptr;
-using std::unordered_map;
-using std::unordered_set;
using std::vector;
namespace pv {
TraceTreeItemOwner* View::find_prevalent_trace_group(
const shared_ptr<sigrok::ChannelGroup> &group,
- const unordered_map<shared_ptr<data::SignalBase>, shared_ptr<Signal> >
- &signal_map)
+ const map<shared_ptr<data::SignalBase>, shared_ptr<Signal> > &signal_map)
{
assert(group);
- unordered_set<TraceTreeItemOwner*> owners;
+ set<TraceTreeItemOwner*> owners;
vector<TraceTreeItemOwner*> owner_list;
// Make a set and a list of all the owners
vector< shared_ptr<Trace> > View::extract_new_traces_for_channels(
const vector< shared_ptr<sigrok::Channel> > &channels,
- const unordered_map<shared_ptr<data::SignalBase>, shared_ptr<Signal> >
- &signal_map,
+ const map<shared_ptr<data::SignalBase>, shared_ptr<Signal> > &signal_map,
set< shared_ptr<Trace> > &add_list)
{
vector< shared_ptr<Trace> > filtered_traces;
inserter(remove_traces, remove_traces.begin()));
// Make a look-up table of sigrok Channels to pulseview Signals
- unordered_map<shared_ptr<data::SignalBase>, shared_ptr<Signal> >
- signal_map;
+ map<shared_ptr<data::SignalBase>, shared_ptr<Signal> > signal_map;
for (const shared_ptr<Signal>& sig : signals_)
signal_map[sig->base()] = sig;
// Add and position the pending top levels items
int offset = v_extents().second;
- for (auto item : new_top_level_items) {
+ for (shared_ptr<TraceTreeItem> item : new_top_level_items) {
add_child_item(item);
// Position the item after the last item or at the top if there is none
#include <list>
#include <memory>
#include <set>
-#include <unordered_map>
#include <vector>
#include <QAbstractScrollArea>
#include "tracetreeitemowner.hpp"
using std::list;
-using std::unordered_map;
+using std::map;
using std::set;
using std::shared_ptr;
using std::vector;
TraceTreeItemOwner* find_prevalent_trace_group(
const shared_ptr<sigrok::ChannelGroup> &group,
- const unordered_map<shared_ptr<data::SignalBase>,
- shared_ptr<Signal> > &signal_map);
+ const map<shared_ptr<data::SignalBase>, shared_ptr<Signal> > &signal_map);
static vector< shared_ptr<Trace> >
extract_new_traces_for_channels(
const vector< shared_ptr<sigrok::Channel> > &channels,
- const unordered_map<shared_ptr<data::SignalBase>,
- shared_ptr<Signal> > &signal_map,
+ const map<shared_ptr<data::SignalBase>, shared_ptr<Signal> > &signal_map,
set< shared_ptr<Trace> > &add_list);
void determine_time_unit();