X-Git-Url: http://git.code-monkey.de/?a=blobdiff_plain;f=pv%2Fview%2Fanalogsignal.cpp;h=e40042dac9fc4057d20e595473a36fb80fdc5f20;hb=33d5aa61e77e61f700a8d09586724a2f12351c53;hp=63e759f97ed7411922b70e2af4946dd2df643ad9;hpb=80067e4944e111bfa8d6b399812dddaa29d5a4ab;p=pulseview.git diff --git a/pv/view/analogsignal.cpp b/pv/view/analogsignal.cpp index 63e759f..e40042d 100644 --- a/pv/view/analogsignal.cpp +++ b/pv/view/analogsignal.cpp @@ -608,13 +608,17 @@ void AnalogSignal::perform_autoranging(bool keep_divs, bool force_update) // If there is still no positive div when we need it, add one // (this can happen when pos_vdivs==neg_vdivs==0) - if ((max > 0) && (pos_vdivs_ == 0)) + if ((max > 0) && (pos_vdivs_ == 0)) { pos_vdivs_ = 1; + owner_->extents_changed(false, true); + } // If there is still no negative div when we need it, add one // (this can happen when pos_vdivs was 0 or 1 when trying to split) - if ((min < 0) && (neg_vdivs_ == 0)) + if ((min < 0) && (neg_vdivs_ == 0)) { neg_vdivs_ = 1; + owner_->extents_changed(false, true); + } double min_value_per_div; if ((pos_vdivs_ > 0) && (neg_vdivs_ > 0)) @@ -696,7 +700,7 @@ void AnalogSignal::populate_popup_form(QWidget *parent, QFormLayout *form) cur_idx = conversion_cb_->findData(QVariant(conversion_type_)); conversion_cb_->setCurrentIndex(cur_idx); - layout->addRow(tr("Conversion"), conversion_cb_); +// layout->addRow(tr("Conversion"), conversion_cb_); connect(conversion_cb_, SIGNAL(currentIndexChanged(int)), this, SLOT(on_conversion_changed(int))); @@ -711,7 +715,7 @@ void AnalogSignal::populate_popup_form(QWidget *parent, QFormLayout *form) cur_idx = display_type_cb_->findData(QVariant(display_type_)); display_type_cb_->setCurrentIndex(cur_idx); - layout->addRow(tr("Traces to show:"), display_type_cb_); +// layout->addRow(tr("Traces to show:"), display_type_cb_); connect(display_type_cb_, SIGNAL(currentIndexChanged(int)), this, SLOT(on_display_type_changed(int))); @@ -722,12 +726,6 @@ void AnalogSignal::populate_popup_form(QWidget *parent, QFormLayout *form) void AnalogSignal::on_samples_added() { perform_autoranging(false, false); - - if (owner_) { - // Call order is important, otherwise the lazy event handler won't work - owner_->extents_changed(false, true); - owner_->row_item_appearance_changed(false, true); - } } void AnalogSignal::on_pos_vdivs_changed(int vdivs)