Use class enums and constants rather than global enums and define

Fix a bug : virtual transferts must not be considered as a debit
This commit is contained in:
2011-08-16 18:22:35 +02:00
parent 6d0fe8ec7b
commit 08ba72664c
20 changed files with 97 additions and 112 deletions

View File

@@ -83,7 +83,7 @@ GenerateDialog::GenerateDialog(KissCount* kiss, wxUI *parent, int month, int yea
{
for(i=0; i<(int)_monthFrom->GetCount(); i++)
{
if (_monthFrom->GetString(i) == months[month])
if (_monthFrom->GetString(i) == wxUI::months[month])
{
toSelect = i;
break;
@@ -158,7 +158,7 @@ void GenerateDialog::OnYearFromChange(wxCommandEvent& event)
year = wxAtoi(years);
for(it=_ops[year].begin(); it!=_ops[year].end(); it++)
_monthFrom->Append(months[*it]);
_monthFrom->Append(wxUI::months[*it]);
_monthFrom->Select(0);
Layout();
@@ -184,7 +184,7 @@ void GenerateDialog::OnYearToChange(wxCommandEvent& event)
}
}
if (ok)
_monthTo->Append(months[i]);
_monthTo->Append(wxUI::months[i]);
}
_monthTo->Select(0);
@@ -205,7 +205,7 @@ void GenerateDialog::OnOK(wxCommandEvent& event)
{
for (i=0; i<12; i++)
{
if (months[i] == _monthFrom->GetString(_monthFrom->GetCurrentSelection()))
if (wxUI::months[i] == _monthFrom->GetString(_monthFrom->GetCurrentSelection()))
{
monthFrom = i;
break;
@@ -216,7 +216,7 @@ void GenerateDialog::OnOK(wxCommandEvent& event)
for (i=0; i<12; i++)
{
if (months[i] == _monthTo->GetString(_monthTo->GetCurrentSelection()))
if (wxUI::months[i] == _monthTo->GetString(_monthTo->GetCurrentSelection()))
{
monthTo = i;
break;