fd->setFilters( aFilters );
fd->myPublishChk->setChecked( true );
fd->mySaveGUIChk->setChecked( true );
- fd->exec();
- QString aFileName = fd->selectedFile();
+ QString aFileName;
+ while (1) {
+ fd->exec();
+ fd->raise();
+ aFileName = fd->selectedFile();
+ if (!aFileName.isEmpty()) {
+ if ( (aFileName.find('-', 0) == -1) && (aFileName.find('!', 0) == -1) && (aFileName.find('?', 0) == -1) &&
+ (aFileName.find('#', 0) == -1) && (aFileName.find('*', 0) == -1) && (aFileName.find('&', 0) == -1)) {
+ break;
+ }
+ else {
+ SUIT_MessageBox::warn1 ( desktop(),
+ QObject::tr("WRN_WARNING"),
+ tr("WRN_FILE_NAME_BAD"),
+ QObject::tr("BUT_OK") );
+ }
+ }
+ else {
+ break;
+ }
+ }
bool toPublish = fd->myPublishChk->isChecked();
bool toSaveGUI = fd->mySaveGUIChk->isChecked();
delete fd;
msgid "SalomeApp_Application::WRN_DUMP_STUDY_FAILED"
msgstr "Dump study failed"
+msgid "SalomeApp_Application::WRN_FILE_NAME_BAD"
+msgstr "Please enter correct file name"
+
msgid "SAVE_POINT_OBJECT_TOOLTIP"
msgstr "Saved GUI state: %1"