mirror of
https://github.com/jankae/LibreVNA.git
synced 2026-04-06 15:04:11 +00:00
Updated graphs to use new math system
This commit is contained in:
parent
a7ff3d60fb
commit
49f9b5442d
16 changed files with 263 additions and 518 deletions
|
|
@ -53,12 +53,14 @@ void TracePlot::enableTrace(Trace *t, bool enabled)
|
|||
connect(t, &Trace::visibilityChanged, this, &TracePlot::triggerReplot);
|
||||
connect(t, &Trace::markerAdded, this, &TracePlot::markerAdded);
|
||||
connect(t, &Trace::markerRemoved, this, &TracePlot::markerRemoved);
|
||||
connect(t, &Trace::typeChanged, this, &TracePlot::checkIfStillSupported);
|
||||
} else {
|
||||
// disconnect from notifications
|
||||
disconnect(t, &Trace::dataChanged, this, &TracePlot::triggerReplot);
|
||||
disconnect(t, &Trace::visibilityChanged, this, &TracePlot::triggerReplot);
|
||||
disconnect(t, &Trace::markerAdded, this, &TracePlot::markerAdded);
|
||||
disconnect(t, &Trace::markerRemoved, this, &TracePlot::markerRemoved);
|
||||
disconnect(t, &Trace::typeChanged, this, &TracePlot::checkIfStillSupported);
|
||||
}
|
||||
updateContextMenu();
|
||||
replot();
|
||||
|
|
@ -271,6 +273,14 @@ void TracePlot::triggerReplot()
|
|||
}
|
||||
}
|
||||
|
||||
void TracePlot::checkIfStillSupported(Trace *t)
|
||||
{
|
||||
if(!supported(t)) {
|
||||
// something with this trace changed and it can no longer be displayed on this graph
|
||||
enableTrace(t, false);
|
||||
}
|
||||
}
|
||||
|
||||
void TracePlot::markerAdded(TraceMarker *m)
|
||||
{
|
||||
connect(m, &TraceMarker::dataChanged, this, &TracePlot::triggerReplot);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue