-// Copyright (C) 2007-2014 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
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" );
}