EgtGraphics :

- funzione di controllo chiave portata in Include per essere usata anche al caricamento Dll.
This commit is contained in:
Dario Sassi
2015-05-26 15:50:03 +00:00
parent 54965e6fba
commit 972d5c1e47
+2 -13
View File
@@ -16,6 +16,7 @@
#include "Scene.h"
#include "GraphObjs.h"
#include "DllMain.h"
#include "/EgtDev/Include/EGrDllMain.h"
#include "/EgtDev/Include/EgtILogger.h"
#include "/EgtDev/Include/EGnStringUtils.h"
#include "/EgtDev/Include/EGkFrame3d.h"
@@ -37,20 +38,8 @@ IEGrScene*
CreateEGrScene( void)
{
// verifico la chiave e le opzioni
unsigned int nOpt1, nOpt2 ;
int nOptExpDays ;
int nRet = GetKeyOptions( GetEGrKey(), KEY_BASELIB_PROD, KEY_BASELIB_VER, KEY_BASELIB_LEV,
nOpt1, nOpt2, nOptExpDays) ;
if ( nRet != KEY_OK) {
string sErr = "Error on Key (GRC/" + ToString( nRet) + ")" ;
LOG_ERROR( GetEGrLogger(), sErr.c_str()) ;
if ( ! TestKeyForEGr( GetEGrKey(), 0, GetEGrLogger()))
return false ;
}
if ( (nOpt1 & KEYOPT_EGR_BASE) == 0 || nOptExpDays < GetCurrDay()) {
string sErr = "Error on Key (GRC/OPT)" ;
LOG_ERROR( GetEGrLogger(), sErr.c_str()) ;
return false ;
}
// creo l'oggetto
return static_cast<IEGrScene*> ( new(nothrow) Scene) ;
}