aggiunto metodo get_version per poter avere un unico sorgente 11 e 12
git-svn-id: svn://10.65.10.50/branches/R_10_00@23085 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
b89e338952
commit
5f9e60b3d7
@ -559,11 +559,19 @@ bool TApplication::get_version_info(int& year, int& release, int& tag, int& patc
|
|||||||
patch = vep.get_int();
|
patch = vep.get_int();
|
||||||
int checksum = vep.get_int();
|
int checksum = vep.get_int();
|
||||||
|
|
||||||
bool valid = year >= 2091 && release > 0 && tag >= 0 && patch >= 0 &&
|
bool valid = year >= 2121 && release > 0 && tag >= 0 && patch >= 0 &&
|
||||||
checksum == (year + release + tag + patch);
|
checksum == (year + release + tag + patch);
|
||||||
return valid;
|
return valid;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
int TApplication::get_version()
|
||||||
|
{
|
||||||
|
int year = 0, release = 0, tag = 0, patch = 0;
|
||||||
|
if (!get_version_info(year, release, tag, patch))
|
||||||
|
release = 0;
|
||||||
|
return release;
|
||||||
|
}
|
||||||
|
|
||||||
// Risposta alla selezione Stampa del menu File
|
// Risposta alla selezione Stampa del menu File
|
||||||
void TApplication::print()
|
void TApplication::print()
|
||||||
{
|
{
|
||||||
|
@ -171,6 +171,7 @@ public:
|
|||||||
|
|
||||||
// @cmember Ritorna i numeri della versione del programma
|
// @cmember Ritorna i numeri della versione del programma
|
||||||
static bool get_version_info(int& year, int& release, int& tag, int& patch);
|
static bool get_version_info(int& year, int& release, int& tag, int& patch);
|
||||||
|
static int get_version();
|
||||||
|
|
||||||
// @cmember Controlla se il modulo <p module> ha l'autorizzazione all'esecuzione
|
// @cmember Controlla se il modulo <p module> ha l'autorizzazione all'esecuzione
|
||||||
bool has_module(int module, int checktype = CHK_ALL) const;
|
bool has_module(int module, int checktype = CHK_ALL) const;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user