X-Git-Url: https://sigrok.org/gitweb/?p=pulseview.git;a=blobdiff_plain;f=pv%2Fview%2Fdecodetrace.cpp;h=b2ead1a66848600e1ae11425fe874d708b73f39a;hp=95e0e5e9ef0f2d4ddfd0692da1ab478846351190;hb=520362f8c4082820193f09e43b27a8c7df2ef011;hpb=f765c3db91d60e9b038ee05f2fa6acc8587d8470 diff --git a/pv/view/decodetrace.cpp b/pv/view/decodetrace.cpp index 95e0e5e9..b2ead1a6 100644 --- a/pv/view/decodetrace.cpp +++ b/pv/view/decodetrace.cpp @@ -199,8 +199,8 @@ void DecodeTrace::paint_mid(QPainter &p, const ViewItemPaintParams &pp) const vector rows(decoder_stack_->get_visible_rows()); visible_rows_.clear(); - for (size_t i = 0; i < rows.size(); i++) { - const Row &row = rows[i]; + for (auto i : rows) { + const Row &row = i; // Cache the row title widths int row_title_width; @@ -229,7 +229,7 @@ void DecodeTrace::paint_mid(QPainter &p, const ViewItemPaintParams &pp) y += row_height_; - visible_rows_.push_back(rows[i]); + visible_rows_.push_back(i); } }