Salome HOME
updated copyright message
[modules/gui.git] / src / SUITApp / SUITApp_Application.cxx
index 4639f100d79933cce38cbf6c192eed56eca62494..72124f1578b3736f866cbb53d92c71d83b7be10c 100644 (file)
@@ -1,28 +1,33 @@
-// Copyright (C) 2005  OPEN CASCADE, CEA/DEN, EDF R&D, PRINCIPIA R&D
-// 
+// Copyright (C) 2007-2023  CEA/DEN, EDF R&D, OPEN CASCADE
+//
+// Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+//
 // This library is free software; you can redistribute it and/or
 // modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either 
-// version 2.1 of the License.
-// 
-// This library is distributed in the hope that it will be useful 
-// but WITHOUT ANY WARRANTY; without even the implied warranty of 
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU 
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 // Lesser General Public License for more details.
 //
-// You should have received a copy of the GNU Lesser General Public  
-// License along with this library; if not, write to the Free Software 
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
 //
 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
 //
+
 #include "SUITApp_Application.h"
 
-#include "SUIT_MessageBox.h"
-#include "SUIT_ExceptionHandler.h"
+#include <SUIT_Tools.h>
+#include <SUIT_ExceptionHandler.h>
 
-#include <qdir.h>
-#include <qfileinfo.h>
+#include <Qtx.h>
+
+#include <QDir>
 
 #ifdef WIN32
 #include <windows.h>
   Constructor
 */
 SUITApp_Application::SUITApp_Application( int& argc, char** argv, SUIT_ExceptionHandler* hand )
-: QApplication( argc, argv ),
-myExceptHandler( hand )
-{
-  QString path = QFileInfo( argv[0] ).dirPath() + QDir::separator() + "../../resources";
-  path = QDir::convertSeparators( QDir( path ).canonicalPath() );
-
-  QTranslator* strTbl = new QTranslator( 0 );
-  if ( strTbl->load( "SUITApp_msg_en.po", path  ) )
-    installTranslator( strTbl );
-  else
-    delete strTbl;
-}
-
-/*!
-  Constructor
-*/
-SUITApp_Application::SUITApp_Application( int& argc, char** argv, Type type, SUIT_ExceptionHandler* hand )
-: QApplication( argc, argv, type ),
+  : QApplication( argc, argv ), 
 myExceptHandler( hand )
 {
-    QTranslator* strTbl = new QTranslator( 0 );
-    strTbl->load( "resources\\SUITApp_msg_en.po" );
-    installTranslator( strTbl );
 }
 
 /*!
@@ -78,7 +63,7 @@ bool SUITApp_Application::notify( QObject* receiver, QEvent* e )
 */
 void SUITApp_Application::setHandler( SUIT_ExceptionHandler* hand )
 {
-       myExceptHandler = hand;
+  myExceptHandler = hand;
 }
 
 /*!