-
- wxBitmapButton *but;
-
- but = new wxBitmapButton(this, ID_LIST_MODE,
- wxArtProvider::GetBitmap(wxART_LIST_VIEW, wxART_BUTTON));
-#if wxUSE_TOOLTIPS
- but->SetToolTip( _("View files as a list view") );
-#endif
- buttonsizer->Add( but, 0, wxALL, 5 );
-
- but = new wxBitmapButton(this, ID_REPORT_MODE,
- wxArtProvider::GetBitmap(wxART_REPORT_VIEW, wxART_BUTTON));
-#if wxUSE_TOOLTIPS
- but->SetToolTip( _("View files as a detailed view") );
-#endif
- buttonsizer->Add( but, 0, wxALL, 5 );
-
+ AddBitmapButton( ID_LIST_MODE, wxART_LIST_VIEW,
+ _("View files as a list view"), buttonsizer );
+ AddBitmapButton( ID_REPORT_MODE, wxART_REPORT_VIEW,
+ _("View files as a detailed view"), buttonsizer );