]> SALOME platform Git repositories - modules/gui.git/commitdiff
Salome HOME
#2090: External 20694 Drive Guithare by a script, without opening it
authorvtn <vtn@opencascade.com>
Tue, 13 May 2014 08:34:29 +0000 (12:34 +0400)
committervtn <vtn@opencascade.com>
Tue, 13 May 2014 08:34:29 +0000 (12:34 +0400)
src/SUIT/SUIT_Session.cxx

index 9cb7c1a0233f429a12817ff09667807e657d3c22..fecc67c4369aa30c0fe633b2fccb03df1c90deb1 100755 (executable)
@@ -714,8 +714,10 @@ void SUIT_Session::restoreBackup()
   {
     QWidget* p = activeApplication() ? (QWidget*)activeApplication()->desktop() : 0;
     
-    int aBtn = SUIT_MessageBox::warning( p, tr( "WRN_WARNING" ), tr( "WANT_TO_RESTORE" ),
-      SUIT_MessageBox::Yes | SUIT_MessageBox::No, SUIT_MessageBox::Yes );
+    int aBtn = SUIT_MessageBox::No;
+    if ( !getenv( "SALOME_BATCH_MODE" ) )
+      aBtn = SUIT_MessageBox::warning( p, tr( "WRN_WARNING" ), tr( "WANT_TO_RESTORE" ),
+        SUIT_MessageBox::Yes | SUIT_MessageBox::No, SUIT_MessageBox::Yes );
     if ( aBtn == SUIT_MessageBox::Yes )
     {
       QStringList::iterator it;