]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
Do not show SUIT_FileDialog in batch mode.
authorvtn <vtn@opencascade.com>
Fri, 19 Jun 2015 15:01:17 +0000 (18:01 +0300)
committervtn <vtn@opencascade.com>
Fri, 19 Jun 2015 15:01:17 +0000 (18:01 +0300)
src/SUIT/SUIT_FileDlg.cxx
src/SUIT/SUIT_FileDlg.h

index f2f8d4c1ba45991404f3e8aa09df1fb8cc8c4f6e..1a9c364d42cd7df4bdd5d1833b809a2cff63faf9 100755 (executable)
@@ -178,6 +178,15 @@ SUIT_FileDlg::~SUIT_FileDlg()
   setValidator( 0 );
 }
 
+/*!
+  \brief Returns Rejected in batch mode.
+*/
+int SUIT_FileDlg::exec()
+{
+  if ( getenv( "SALOME_BATCH_MODE" ) )
+    return QDialog::Rejected;
+  return QFileDialog::exec();
+}
 
 /*! 
   \brief Check if the dialog box is used for opening or saving the file.
index f8fa14ea30f248d6951c0443b0b6eae5fec33877..0f6a457983bde913abd2a2b8c5d3a85d8972549f 100755 (executable)
@@ -59,6 +59,8 @@ public:
 
   void selectFile( const QString& );
 
+  int exec();
+
   static QString      getLastVisitedDirectory();
 
   static QString      getFileName( QWidget*,