From: dmv Date: Wed, 26 Nov 2008 10:35:41 +0000 (+0000) Subject: correct integrations for [Bug IPAL20699] Export to UNV X-Git-Tag: PARAVIS_TEST~11 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=29c374e0bd66c939c97b4e0884a2abf5dd0cc33a;p=modules%2Fgui.git correct integrations for [Bug IPAL20699] Export to UNV --- diff --git a/src/SUIT/SUIT_FileDlg.cxx b/src/SUIT/SUIT_FileDlg.cxx index 9c3d4aadd..ed1c2fd10 100755 --- a/src/SUIT/SUIT_FileDlg.cxx +++ b/src/SUIT/SUIT_FileDlg.cxx @@ -731,9 +731,9 @@ QString SUIT_FileDlg::getFileName( QWidget* parent, const QString& initial, fd.setFileMode( open ? ExistingFile : AnyFile ); - QString filename = initial; - filename.simplified(); - filename = filename.replace(QRegExp("\\*"), "" ).replace(QRegExp("\\?"), "" ); + QString tmpfilename = initial; + tmpfilename = tmpfilename.simplified(); + tmpfilename = tmpfilename.replace(QRegExp("\\*"), "" ).replace(QRegExp("\\?"), "" ); if ( filters.isEmpty() ) fd.setFilter( tr( "ALL_FILES_FILTER" ) ); // All files (*) @@ -743,16 +743,16 @@ QString SUIT_FileDlg::getFileName( QWidget* parent, const QString& initial, if ( !caption.isEmpty() ) fd.setWindowTitle( caption ); - if ( !filename.isEmpty() ) - fd.processPath( filename ); + if ( !tmpfilename.isEmpty() ) + fd.processPath( tmpfilename ); if ( validator ) fd.setValidator( validator ); + QString filename; + if ( fd.exec() == QDialog::Accepted ) filename = fd.selectedFile(); - else - filename = ""; QApplication::processEvents();