fix on the saving setting dialog
This commit is contained in:
parent
4020a2aeac
commit
187b3b5b7f
|
@ -4023,18 +4023,11 @@ void DigiSettingsPanel::SaveSetting(int opt){
|
|||
|
||||
QString filePath = QFileDialog::getSaveFileName(this,
|
||||
"Save Settings File",
|
||||
rawDataPath,
|
||||
QDir::toNativeSeparators(rawDataPath + "/" + defaultFileName),
|
||||
opt == 0 ? "Binary (*.bin)" : "Text file (*.txt)");
|
||||
|
||||
if (!filePath.isEmpty()) {
|
||||
|
||||
QFileDialog dialog;
|
||||
dialog.selectFile(defaultFileName);
|
||||
|
||||
if( dialog.exec() == QDialog::Accepted){
|
||||
|
||||
filePath = dialog.selectedFiles().first();
|
||||
|
||||
QFileInfo fileInfo(filePath);
|
||||
QString ext = fileInfo.suffix();
|
||||
if( opt == 0 ){
|
||||
|
@ -4052,8 +4045,6 @@ void DigiSettingsPanel::SaveSetting(int opt){
|
|||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void DigiSettingsPanel::LoadSetting(){
|
||||
|
|
Loading…
Reference in New Issue
Block a user