X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=pv%2Fsubwindows%2Fdecoder_selector%2Fsubwindow.cpp;h=0c4b76bb8c14aca9fcb58688f037579c205dd13e;hb=HEAD;hp=94ed6f4b6da970e02a3191ba2a87dc7d951bd054;hpb=0466001be51e779b23aaebec1cc9361305c07be9;p=pulseview.git diff --git a/pv/subwindows/decoder_selector/subwindow.cpp b/pv/subwindows/decoder_selector/subwindow.cpp index 94ed6f4b..0c4b76bb 100644 --- a/pv/subwindows/decoder_selector/subwindow.cpp +++ b/pv/subwindows/decoder_selector/subwindow.cpp @@ -74,7 +74,8 @@ void QCustomTreeView::currentChanged(const QModelIndex& current, const QModelIndex& previous) { QTreeView::currentChanged(current, previous); - currentChanged(current); + + current_changed(current); } @@ -158,7 +159,7 @@ SubWindow::SubWindow(Session& session, QWidget* parent) : connect(filter, SIGNAL(returnPressed()), this, SLOT(on_filter_return_pressed())); - connect(tree_view_, SIGNAL(currentChanged(const QModelIndex&)), + connect(tree_view_, SIGNAL(current_changed(const QModelIndex&)), this, SLOT(on_item_changed(const QModelIndex&))); connect(tree_view_, SIGNAL(activated(const QModelIndex&)), this, SLOT(on_item_activated(const QModelIndex&))); @@ -185,7 +186,7 @@ QToolBar* SubWindow::create_toolbar(QWidget *parent) const int SubWindow::minimum_width() const { QFontMetrics m(info_label_body_->font()); - const int label_width = m.width(QString(tr(initial_notice))); + const int label_width = util::text_width(m, tr(initial_notice)); return label_width + min_width_margin; }