From 05306a598620f8eecd320abc606d1cff4b96f333 Mon Sep 17 00:00:00 2001 From: tbaudier Date: Mon, 4 Mar 2019 16:47:12 +0100 Subject: [PATCH] Change name of the button in Image Arithm tool Before, it was QDialogButtonBox::Discard, but according to https://doc.qt.io/archives/qt-4.8/qdialogbuttonbox.html#StandardButton-enum it can be displayed "Don't save". For this tool, we want to select 1 image instead of 2, so the name of the button is not appropriate. Moreover in skip function, the comparision to "Discard" can be complicated with another name. So I prefer to use Ignore button because it's more appropriate --- vv/vvToolSimpleInputSelectorWidget.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/vv/vvToolSimpleInputSelectorWidget.cxx b/vv/vvToolSimpleInputSelectorWidget.cxx index 49c5dbc..9ecadb4 100644 --- a/vv/vvToolSimpleInputSelectorWidget.cxx +++ b/vv/vvToolSimpleInputSelectorWidget.cxx @@ -66,7 +66,7 @@ void vvToolSimpleInputSelectorWidget::EnableAllowSkip(bool b) { mAllowSkip = b; if (mAllowSkip) { - mInputSelectionButtonBox->setStandardButtons(QDialogButtonBox::Cancel|QDialogButtonBox::Ok|QDialogButtonBox::Discard); + mInputSelectionButtonBox->setStandardButtons(QDialogButtonBox::Cancel|QDialogButtonBox::Ok|QDialogButtonBox::Ignore); connect(mInputSelectionButtonBox, SIGNAL(clicked(QAbstractButton*)), this, SLOT(skip(QAbstractButton*))); } else mInputSelectionButtonBox->setStandardButtons(QDialogButtonBox::Cancel|QDialogButtonBox::Ok); @@ -128,7 +128,7 @@ void vvToolSimpleInputSelectorWidget::reject() //------------------------------------------------------------------------------ void vvToolSimpleInputSelectorWidget::skip(QAbstractButton* b) { - if (b->text() == "Discard") emit sigskip(); + if (b->text() == "Ignore") emit sigskip(); } //------------------------------------------------------------------------------ -- 2.47.1