Use a sizer for menu generate

This commit is contained in:
Grégory Soutadé 2011-01-29 21:01:01 +01:00
parent 1151daf861
commit bd4809042b

View File

@ -38,10 +38,11 @@ GenerateDialog::GenerateDialog(KissCount* kiss, wxUI *parent, int month, int yea
wxCommandEvent event; wxCommandEvent event;
std::vector<int>::iterator monthIt; std::vector<int>::iterator monthIt;
curDate.SetToCurrent(); wxBoxSizer *hbox = new wxBoxSizer(wxHORIZONTAL);
gridBagSizer = new wxGridBagSizer(4, 5); gridBagSizer = new wxGridBagSizer(4, 5);
curDate.SetToCurrent();
label = new wxStaticText(this, wxID_ANY, _("From ")); label = new wxStaticText(this, wxID_ANY, _("From "));
gridBagSizer->Add(label, wxGBPosition(0, 0)); gridBagSizer->Add(label, wxGBPosition(0, 0));
_yearFrom = new wxChoice(this, YEAR_FROM_ID); _yearFrom = new wxChoice(this, YEAR_FROM_ID);
@ -133,9 +134,10 @@ GenerateDialog::GenerateDialog(KissCount* kiss, wxUI *parent, int month, int yea
} }
} }
SetSizer(gridBagSizer); hbox->Add(gridBagSizer, 0, wxGROW|wxALL, 10);
SetSizer(hbox);
Layout(); Fit();
Center(); Center();
} }