Patch level :4.0 799
Files correlati :cg2.exe sc0.exe Ricompilazione Demo : [ ] Commento :riportate correzioni sul saldaconto dalla 3.1 git-svn-id: svn://10.65.10.50/trunk@15694 c028cbd2-c16b-5b4b-a496-9718f37d4682
This commit is contained in:
parent
8679571d1a
commit
17b6eed969
@ -1815,11 +1815,15 @@ static int sort_games_date(const TObject** o1, const TObject** o2)
|
|||||||
void TGame_mask::sort_partite()
|
void TGame_mask::sort_partite()
|
||||||
{
|
{
|
||||||
TString_array& a = partite().rows_array();
|
TString_array& a = partite().rows_array();
|
||||||
const int last = a.last();
|
|
||||||
if (last > 1)
|
// Elimina riga saldo se presente
|
||||||
|
int last = a.last();
|
||||||
|
if (last > 0 && a.row(last).get_int(0) == 0) // Se l'anno dell'ultima riga e' nullo ...
|
||||||
|
a.destroy(last--); // ... elimina riga saldo
|
||||||
|
|
||||||
|
// Ordina lista se necessario (ci sono almeno due partite)
|
||||||
|
if (last > 0)
|
||||||
{
|
{
|
||||||
if (a.row(last).get_int(0) == 0) // Se non c'e' l'anno ...
|
|
||||||
a.destroy(last); // ... elimina riga saldo
|
|
||||||
switch (get(P_SORT)[0])
|
switch (get(P_SORT)[0])
|
||||||
{
|
{
|
||||||
case 'N': a.TArray::sort(sort_games_num); break; // Ordine numerico
|
case 'N': a.TArray::sort(sort_games_num); break; // Ordine numerico
|
||||||
@ -1827,8 +1831,9 @@ void TGame_mask::sort_partite()
|
|||||||
default : a.sort(); break; // Ordine alfabetico
|
default : a.sort(); break; // Ordine alfabetico
|
||||||
}
|
}
|
||||||
update_saldo_clifo(); // Ricrea riga saldo
|
update_saldo_clifo(); // Ricrea riga saldo
|
||||||
partite().force_update(); // Aggiorna lo spreadsheet
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
partite().force_update(); // Aggiorna lo spreadsheet
|
||||||
}
|
}
|
||||||
|
|
||||||
void TGame_mask::fill_partite()
|
void TGame_mask::fill_partite()
|
||||||
@ -1854,7 +1859,7 @@ void TGame_mask::fill_partite()
|
|||||||
bool u = (k.tipo() > ' ' && k.sottoconto() == conto().sottoconto()) || k == conto();
|
bool u = (k.tipo() > ' ' && k.sottoconto() == conto().sottoconto()) || k == conto();
|
||||||
|
|
||||||
if (u && !all && gioco->chiusa() && gioco->mov2rig(_numreg, _numrig) <= 0)
|
if (u && !all && gioco->chiusa() && gioco->mov2rig(_numreg, _numrig) <= 0)
|
||||||
u = FALSE;
|
u = false;
|
||||||
|
|
||||||
if (u)
|
if (u)
|
||||||
update_partita(*gioco, -1);
|
update_partita(*gioco, -1);
|
||||||
@ -1895,7 +1900,7 @@ void TGame_mask::fill_partite()
|
|||||||
sort_partite();
|
sort_partite();
|
||||||
aggiorna_residuo();
|
aggiorna_residuo();
|
||||||
|
|
||||||
if (a.items() > 1)
|
if (!a.empty())
|
||||||
{
|
{
|
||||||
_riga_partite = -1;
|
_riga_partite = -1;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user