mirror of
https://github.com/DreamSourceLab/DSView.git
synced 2025-01-13 13:32:53 +08:00
clean code
This commit is contained in:
parent
94643b4e00
commit
aefa5a7c27
@ -1128,8 +1128,6 @@ namespace pv
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
dsv_info("DSO triged position updated event.");
|
|
||||||
|
|
||||||
int probe_count = 0;
|
int probe_count = 0;
|
||||||
int probe_en_count = 0;
|
int probe_en_count = 0;
|
||||||
|
|
||||||
|
@ -853,8 +853,6 @@ void DsoSignal::paint_mid(QPainter &p, int left, int right, QColor fore, QColor
|
|||||||
(status.ch1_plevel ? status.ch1_cyc_plen - status.ch1_cyc_llen :
|
(status.ch1_plevel ? status.ch1_cyc_plen - status.ch1_cyc_llen :
|
||||||
status.ch1_cyc_tlen - status.ch1_cyc_plen + status.ch1_cyc_llen);
|
status.ch1_cyc_tlen - status.ch1_cyc_plen + status.ch1_cyc_llen);
|
||||||
_high_time = ((count == 0) ? 0 : samples / count) * tfactor;
|
_high_time = ((count == 0) ? 0 : samples / count) * tfactor;
|
||||||
// dsv_info("samples:%f,count:%d,tfactor:%f",
|
|
||||||
// samples, count, tfactor);
|
|
||||||
|
|
||||||
samples = (index == 0) ? status.ch0_cyc_tlen + status.ch0_cyc_llen : status.ch1_cyc_flen + status.ch1_cyc_llen;
|
samples = (index == 0) ? status.ch0_cyc_tlen + status.ch0_cyc_llen : status.ch1_cyc_flen + status.ch1_cyc_llen;
|
||||||
_burst_time = samples * tfactor;
|
_burst_time = samples * tfactor;
|
||||||
@ -1263,13 +1261,6 @@ void DsoSignal::paint_hover_measure(QPainter &p, QColor fore, QColor back)
|
|||||||
// Hover measure
|
// Hover measure
|
||||||
if (_hover_en && _hover_point != QPointF(-1, -1)) {
|
if (_hover_en && _hover_point != QPointF(-1, -1)) {
|
||||||
QString hover_str = get_voltage(hw_offset - _hover_value, 2);
|
QString hover_str = get_voltage(hw_offset - _hover_value, 2);
|
||||||
|
|
||||||
//vf = (hw_offset - (double)(*p)) * mapRange / max_min_ref;
|
|
||||||
//v = v * data_scale * k * _vDial->get_factor() * DS_CONF_DSO_VDIVS / get_view_rect().height();
|
|
||||||
|
|
||||||
// dsv_info("c:%d, hw_offset:%d",
|
|
||||||
// hw_offset - _hover_value, hw_offset);
|
|
||||||
|
|
||||||
const int hover_width = p.boundingRect(0, 0, INT_MAX, INT_MAX,
|
const int hover_width = p.boundingRect(0, 0, INT_MAX, INT_MAX,
|
||||||
Qt::AlignLeft | Qt::AlignTop, hover_str).width() + 10;
|
Qt::AlignLeft | Qt::AlignTop, hover_str).width() + 10;
|
||||||
const int hover_height = p.boundingRect(0, 0, INT_MAX, INT_MAX,
|
const int hover_height = p.boundingRect(0, 0, INT_MAX, INT_MAX,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user