- subsizer->Add(m_bEdit, 0, wxALIGN_CENTRE_VERTICAL);
- subsizer->Add(m_bNew, 0, wxALIGN_CENTRE_VERTICAL);
- subsizer->Add(m_bDel, 0, wxALIGN_CENTRE_VERTICAL);
- subsizer->Add(m_bUp, 0, wxALIGN_CENTRE_VERTICAL);
- subsizer->Add(m_bDown, 0, wxALIGN_CENTRE_VERTICAL);
+ if ( m_style & wxEL_ALLOW_NEW )
+ {
+ m_bNew = new wxBitmapButton(subp, wxID_ELB_NEW, wxBitmap(elnew_xpm));
+ subsizer->Add(m_bNew, 0, wxALIGN_CENTRE_VERTICAL | wxTOP | wxBOTTOM, BTN_BORDER);
+ }
+
+ if ( m_style & wxEL_ALLOW_DELETE )
+ {
+ m_bDel = new wxBitmapButton(subp, wxID_ELB_DELETE, wxBitmap(eldel_xpm));
+ subsizer->Add(m_bDel, 0, wxALIGN_CENTRE_VERTICAL | wxTOP | wxBOTTOM, BTN_BORDER);
+ }
+
+ m_bUp = new wxBitmapButton(subp, wxID_ELB_UP, wxBitmap(elup_xpm));
+ subsizer->Add(m_bUp, 0, wxALIGN_CENTRE_VERTICAL | wxTOP | wxBOTTOM, BTN_BORDER);
+
+ m_bDown = new wxBitmapButton(subp, wxID_ELB_DOWN, wxBitmap(eldown_xpm));
+ subsizer->Add(m_bDown, 0, wxALIGN_CENTRE_VERTICAL | wxTOP | wxBOTTOM, BTN_BORDER);
+
+#if wxUSE_TOOLTIPS
+ if ( m_bEdit ) m_bEdit->SetToolTip(_("Edit item"));
+ if ( m_bNew ) m_bNew->SetToolTip(_("New item"));
+ if ( m_bDel ) m_bDel->SetToolTip(_("Delete item"));
+ m_bUp->SetToolTip(_("Move up"));
+ m_bDown->SetToolTip(_("Move down"));
+#endif