22 #include <QFileDialog> 54 QFileDialog * dialog =
new QFileDialog(
this);
55 dialog->setFileMode(QFileDialog::ExistingFile);
57 dialog->setNameFilter(tr(
"Dcm2nii (dcm2nii)"));
59 dialog->setNameFilter(tr(
"Dcm2nii (dcm2nii.exe)"));
61 dialog->setDirectory(QDir::home().dirName());
62 dialog->setWindowTitle(
"Choose dcm2nii path");
66 filename = dialog->selectedFiles()[0];
69 if (!filename.isEmpty())
73 dcm2niiLineEdit->setText(filename);
79 dcm2niiPathFrame->setEnabled((state == Qt::Checked));
static QtDcmPreferences * instance()
void setUseDcm2nii(bool use)
void setDcm2niiPath(const QString &path)