- if (m_buttonCancel){
- Add((wxWindow*)m_buttonCancel, 0, wxALIGN_CENTRE | wxLEFT | wxRIGHT, 3);
- // Cancel or help should be default
- // m_buttonCancel->SetDefaultButton();
+ Add((wxWindow*)m_buttonApply,
+ 0, wxALIGN_CENTRE | wxLEFT | wxRIGHT, 3);
+
+ if (m_buttonCancel)
+ Add((wxWindow*)m_buttonCancel,
+ 0, wxALIGN_CENTRE | wxLEFT | wxRIGHT, 3);
+
+ if (m_buttonAffirmative)
+ Add((wxWindow*)m_buttonAffirmative,
+ 0, wxALIGN_CENTRE | wxLEFT, 6);
+ }
+ else
+ {
+ // without an Apply button, have the buttons representing
+ // affirmative and negative close to each other.
+
+ if (m_buttonAffirmative)
+ Add((wxWindow*)m_buttonAffirmative,
+ 0, wxALIGN_CENTRE | wxLEFT | wxRIGHT, 3);
+
+ if (m_buttonCancel)
+ Add((wxWindow*)m_buttonCancel, 0, wxALIGN_CENTRE | wxLEFT, 6);