Use stock GTK+ buttons in the toolbar

This commit is contained in:
Alexander Kojevnikov 2012-09-04 10:31:06 -07:00
parent 73d77e5e92
commit ead812e6da
2 changed files with 18 additions and 3 deletions

View File

@ -36,6 +36,21 @@ wxBitmap SpekArtProvider::CreateBitmap(
if (id == ART_SPEK) { if (id == ART_SPEK) {
#ifdef OS_UNIX #ifdef OS_UNIX
return wxArtProvider::GetBitmap(wxT("spek"), client, size); return wxArtProvider::GetBitmap(wxT("spek"), client, size);
#endif
}
if (id == ART_OPEN) {
#ifdef OS_UNIX
return wxArtProvider::GetBitmap(wxT("gtk-open"), client, size);
#endif
}
if (id == ART_SAVE) {
#ifdef OS_UNIX
return wxArtProvider::GetBitmap(wxT("gtk-save"), client, size);
#endif
}
if (id == ART_ABOUT) {
#ifdef OS_UNIX
return wxArtProvider::GetBitmap(wxT("gtk-about"), client, size);
#endif #endif
} }
return wxNullBitmap; return wxNullBitmap;

View File

@ -111,13 +111,13 @@ SpekWindow::SpekWindow(const wxString& path) :
toolbar->AddTool( toolbar->AddTool(
wxID_OPEN, wxID_OPEN,
wxEmptyString, wxEmptyString,
wxArtProvider::GetBitmap(wxART_FILE_OPEN, wxART_TOOLBAR), wxArtProvider::GetBitmap(ART_OPEN, wxART_TOOLBAR),
menu_file_open->GetItemLabelText() menu_file_open->GetItemLabelText()
); );
toolbar->AddTool( toolbar->AddTool(
wxID_SAVE, wxID_SAVE,
wxEmptyString, wxEmptyString,
wxArtProvider::GetBitmap(wxART_FILE_SAVE, wxART_TOOLBAR), wxArtProvider::GetBitmap(ART_SAVE, wxART_TOOLBAR),
menu_file_save->GetItemLabelText() menu_file_save->GetItemLabelText()
); );
#if wxCHECK_VERSION(2, 9, 1) #if wxCHECK_VERSION(2, 9, 1)
@ -125,7 +125,7 @@ SpekWindow::SpekWindow(const wxString& path) :
toolbar->AddTool( toolbar->AddTool(
wxID_ABOUT, wxID_ABOUT,
wxEmptyString, wxEmptyString,
wxArtProvider::GetBitmap(wxART_HELP, wxART_TOOLBAR), wxArtProvider::GetBitmap(ART_ABOUT, wxART_TOOLBAR),
menu_help_about->GetItemLabelText() menu_help_about->GetItemLabelText()
); );
#endif #endif