From: <ma...@us...> - 2003-12-29 09:12:36
|
Update of /cvsroot/sharedaemon/ui-wx/src In directory sc8-pr-cvs1:/tmp/cvs-serv14478 Modified Files: Images.cpp Log Message: Aint it fun - wxSystemSettings only works on wxMSW! Ohwell, use 50,50,50 col for tbar button images then on wxGTK Index: Images.cpp =================================================================== RCS file: /cvsroot/sharedaemon/ui-wx/src/Images.cpp,v retrieving revision 1.48 retrieving revision 1.49 diff -u -d -r1.48 -r1.49 --- Images.cpp 29 Dec 2003 08:51:22 -0000 1.48 +++ Images.cpp 29 Dec 2003 09:12:33 -0000 1.49 @@ -334,9 +334,13 @@ GetImage(image), (tmp_new.GetWidth()-32)/2, 2, true ); +#ifdef __WXMSW__ /* Well, this gives correct colour on MSW */ mdc.SetTextForeground( wxSystemSettings::GetColour(wxSYS_COLOUR_BTNTEXT) ); +#else /* However, it doesn't work anywhere else, so use 50,50,50 instead */ + mdc.SetTextForeground(wxColour(50, 50, 50)); +#endif mdc.GetTextExtent(name, &x, &y); mdc.DrawText(name, (tmp_new.GetWidth()-x)/2, 36); #ifndef __WXMSW__ /* Use wxMask for transparency */ @@ -438,7 +442,7 @@ /* Check path validity */ - if (wxDirExists(path)) { + if (wxDirExists(path)) { return path; } else { wxLogDebug(wxT("Images were not found in %s."), path.c_str()); |