Salome HOME
updated copyright message
[modules/gui.git] / src / Style / Style_ResourceMgr.cxx
index 34ad0c581a165faec86f0eaa0a948e3bcb29fb3f..9fd95076f72cef41b8f5b1292a897adb470820cc 100644 (file)
@@ -1,9 +1,9 @@
-// Copyright (C) 2007-2013  CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2023  CEA, EDF, OPEN CASCADE
 //
 // 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.
+// 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
@@ -43,8 +43,9 @@
 Style_ResourceMgr::Style_ResourceMgr()
   : QtxResourceMgr( "SalomeStyle", "%1Config" )
 {
-  if ( dirList().isEmpty() && ::getenv( "GUI_ROOT_DIR" ) )
-    setDirList( QStringList() << Qtx::addSlash( ::getenv( "GUI_ROOT_DIR" ) ) + "share/salome/resources/gui" );
+  QString gui_root = Qtx::getenv( "GUI_ROOT_DIR" );
+  if ( dirList().isEmpty() && !gui_root.isEmpty() )
+    setDirList( QStringList() << Qtx::addSlash( gui_root ) + "share/salome/resources/gui" );
   setCurrentFormat( "xml" );
 }