From: Soeren Apel Date: Wed, 13 Dec 2017 16:19:29 +0000 (+0100) Subject: View: Fixes related to multi-segment display X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=3734c4645fc071fe7ecfb552d65d343e50b098e1;p=pulseview.git View: Fixes related to multi-segment display --- diff --git a/pv/views/trace/view.cpp b/pv/views/trace/view.cpp index a79396d1..2bfe68c2 100644 --- a/pv/views/trace/view.cpp +++ b/pv/views/trace/view.cpp @@ -229,6 +229,9 @@ View::View(Session &session, bool is_main_view, QWidget *parent) : // Update the zoom state calculate_tick_spacing(); + + // Make sure the standard bar's segment selector is in sync + set_segment_display_mode(segment_display_mode_); } Session& View::session() @@ -497,7 +500,7 @@ void View::set_segment_display_mode(Trace::SegmentDisplayMode mode) segment_selectable_ = true; - if (mode == Trace::ShowSingleSegmentOnly) + if (mode == Trace::ShowLastSegmentOnly) segment_selectable_ = false; segment_display_mode_changed(segment_selectable_); @@ -1423,6 +1426,8 @@ void View::on_segment_changed(int segment) current_segment_ = segment; for (shared_ptr signal : signals_) signal->set_current_segment(current_segment_); + for (shared_ptr dt : decode_traces_) + dt->set_current_segment(current_segment_); viewport_->update(); break;