Skip to content

Commit c41d530

Browse files
u8621011jcfr
authored andcommitted
ENH: i18n: Add some QTGUI i18n fixes
1 parent 6915f7c commit c41d530

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

Base/QTGUI/qSlicerDataDialog.cxx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,11 @@ qSlicerDataDialogPrivate::qSlicerDataDialogPrivate(QWidget* _parent)
9494
QPushButton* resetButton = this->ButtonBox->button(QDialogButtonBox::Reset);
9595
connect(resetButton, SIGNAL(clicked()), this, SLOT(reset()));
9696

97+
// do the internationalization setup for ButtonBox buttons
98+
this->ButtonBox->button(QDialogButtonBox::Ok)->setText(tr("OK"));
99+
this->ButtonBox->button(QDialogButtonBox::Cancel)->setText(tr("Cancel"));
100+
this->ButtonBox->button(QDialogButtonBox::Reset)->setText(tr("Reset"));
101+
97102
// Authorize Drops action from outside
98103
this->setAcceptDrops(true);
99104

Base/QTGUI/qSlicerSaveDataDialog.cxx

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
#include <QMessageBox>
2727
#include <QRegExp>
2828
#include <QRegExpValidator>
29+
#include <QPushButton>
2930

3031
/// CTK includes
3132
#include <ctkCheckableHeaderView.h>
@@ -192,6 +193,10 @@ qSlicerSaveDataDialogPrivate::qSlicerSaveDataDialogPrivate(QWidget* parentWidget
192193
connect(this->ShowMoreCheckBox, SIGNAL(toggled(bool)),
193194
this, SLOT(showMoreColumns(bool)));
194195
this->showMoreColumns(this->ShowMoreCheckBox->isChecked());
196+
197+
// do the ButtonBox internationalization
198+
this->ButtonBox->button(QDialogButtonBox::Save)->setText(tr("Save"));
199+
this->ButtonBox->button(QDialogButtonBox::Cancel)->setText(tr("Cancel"));
195200
}
196201

197202
//-----------------------------------------------------------------------------

0 commit comments

Comments
 (0)