X-Git-Url: http://git.code-monkey.de/?a=blobdiff_plain;ds=sidebyside;f=pv%2Fviews%2Ftrace%2Flogicsignal.cpp;h=5c6aa54b2779375b5868b4be3d7dde9bff5250f5;hb=b571a8e7e0dc3e3b6daa58f27050e76466f006dd;hp=f43ac37e7ebf5b4d583ca3862d856ba59763d02e;hpb=099d231771d9ff6230218dbe9835a03876f0e856;p=pulseview.git diff --git a/pv/views/trace/logicsignal.cpp b/pv/views/trace/logicsignal.cpp index f43ac37..5c6aa54 100644 --- a/pv/views/trace/logicsignal.cpp +++ b/pv/views/trace/logicsignal.cpp @@ -258,10 +258,11 @@ void LogicSignal::paint_mid(QPainter &p, ViewItemPaintParams &pp) if (fill_high_areas) { // Any edge terminates a high area - const int width = x - rising_edge_x; - if (rising_edge_seen && (width > 0)) { - high_rects.emplace_back(rising_edge_x, high_offset, - width, signal_height_); + if (rising_edge_seen) { + const int width = x - rising_edge_x; + if (width > 0) + high_rects.emplace_back(rising_edge_x, high_offset, + width, signal_height_); rising_edge_seen = false; } @@ -583,7 +584,7 @@ void LogicSignal::populate_popup_form(QWidget *parent, QFormLayout *form) // Only allow triggers to be changed when we're stopped if (session_.get_capture_state() != Session::Stopped) for (QAction* action : trigger_bar_->findChildren()) - action->setEnabled(false); + action->setEnabled(false); // clazy:exclude=range-loop form->addRow(tr("Trigger"), trigger_bar_); }