EgtInterface 1.6e1 :

- migliorata EgtErase per registrazione lua
- migliorata segnalazione stato avvio di EgtMachMgr.
This commit is contained in:
Dario Sassi
2015-05-04 07:33:16 +00:00
parent 758245f4fc
commit e7ee6d9255
3 changed files with 13 additions and 10 deletions
+8 -5
View File
@@ -26,20 +26,23 @@ using namespace std ;
//-----------------------------------------------------------------------------
BOOL
__stdcall EgtInitMachMgr( void)
__stdcall EgtInitMachMgr( const wchar_t* wsMachinesDir)
{
GseContext* pGseCtx = GetCurrGseContext() ;
VERIFY_CTX( pGseCtx, FALSE)
// inizializzazione gestore lavorazioni
PtrOwner<IMachMgr> pMachMgr( MyCreateMachMgr()) ;
VERIFY_NULL( Get( pMachMgr), "Error in CreateMachMgr", FALSE)
pMachMgr->Init( pGseCtx->m_pGeomDB) ;
string sMachinesDir = wstrztoA( wsMachinesDir) ;
bool bOk = pMachMgr->Init( pGseCtx->m_pGeomDB, sMachinesDir) ;
// assegno il gestore al contesto
pGseCtx->m_pMachMgr = Release( pMachMgr) ;
pGseCtx->m_pMachMgr = ( bOk ? Release( pMachMgr) : nullptr) ;
// log avvio Machining Manager
string sLog = "MachMgr started " ;
string sLog = "MachMgr " ;
sLog += ( bOk ? " started" : " error") ;
sLog += " (" + sMachinesDir + ")" ;
LOG_INFO( GetLogger(), sLog.c_str())
return TRUE ;
return ( bOk ? TRUE : FALSE) ;
}
//-----------------------------------------------------------------------------