EgtExecutor 2.1g2 :

- in Estimate aggiunta gestione nome file vuoto (simile a Generate).
This commit is contained in:
Dario Sassi
2019-07-15 06:55:50 +00:00
parent 513372af37
commit 1813f008f4
2 changed files with 19 additions and 1 deletions
+19 -1
View File
@@ -2710,8 +2710,26 @@ ExeEstimate( const string& sEstFile, const string& sInfo)
{
IMachMgr* pMachMgr = GetCurrMachMgr() ;
VERIFY_MACHMGR( pMachMgr, false)
string sMyEstFile = sEstFile ;
// se nome file vuoto
if ( IsEmptyOrSpaces( sMyEstFile)) {
// recupero la path del progetto
string sProjPath ;
if ( ! ExeGetCurrFilePath( sProjPath))
return false ;
// ne deduco il direttorio
string sDir = GetDirectory( sProjPath) ;
ReplaceString( sDir, "/", "\\") ;
// recupero il nome
string sEstName ;
if ( ! ExeGetInfo( ExeGetCurrMachGroup(), GDL_NC_NAME, sEstName))
sEstName = GetFileTitleEgt( sProjPath) ;
sEstName = ChangeFileExtension( sEstName, ".html") ;
// creo la path completa
sMyEstFile = sDir + "\\" + sEstName ;
}
// eseguo la stima di tempi e lunghezze di lavoro della macchinata corrente
return pMachMgr->Estimate( sEstFile, sInfo) ;
return pMachMgr->Estimate( sMyEstFile, sInfo) ;
}
//-----------------------------------------------------------------------------
BIN
View File
Binary file not shown.