X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/b3208e1158e3bbc38b73eeda606d92be9e649c1c..19c43a77ce8d061a162fdb04b0a6b1f7fbe51604:/src/mac/carbon/renderer.cpp diff --git a/src/mac/carbon/renderer.cpp b/src/mac/carbon/renderer.cpp index 5a14e7f08e..07ae99090a 100644 --- a/src/mac/carbon/renderer.cpp +++ b/src/mac/carbon/renderer.cpp @@ -26,6 +26,9 @@ #ifndef WX_PRECOMP #include "wx/string.h" + #include "wx/dc.h" + #include "wx/bitmap.h" + #include "wx/settings.h" #endif //WX_PRECOMP #include "wx/renderer.h" @@ -34,7 +37,7 @@ // wxRendererMac: our wxRendererNative implementation // ---------------------------------------------------------------------------- -class WXDLLEXPORT wxRendererMac : public wxRendererNative +class WXDLLEXPORT wxRendererMac : public wxDelegateRendererNative { public: // draw the header control button (used by wxListCtrl) @@ -53,7 +56,9 @@ public: virtual void DrawSplitterSash(wxWindow *win, wxDC& dc, const wxSize& size, - wxCoord position); + wxCoord position, + wxOrientation orient, + int flags = 0); private: // the tree buttons @@ -114,7 +119,7 @@ static const char *aqua_arrow_down_xpm[] = { // ============================================================================ /* static */ -wxRendererNative& wxRendererMac::Get() +wxRendererNative& wxRendererNative::GetDefault() { static wxRendererMac s_rendererMac; @@ -192,19 +197,22 @@ wxRendererMac::DrawTreeItemButton(wxWindow *win, } void -wxRendererMac::DrawSash(wxWindow *win, - wxDC& dc, - const wxSize& size, - wxCoord position) +wxRendererMac::DrawSplitterSash(wxWindow *win, + wxDC& dc, + const wxSize& size, + wxCoord position, + wxOrientation orient, + int WXUNUSED(flags)) { // VZ: we have to somehow determine if we're drawing a normal sash or // a brushed metal one as they look quite differently... this is // completely bogus anyhow, of course (TODO) - const wxCoord h = size.y; - dc.SetPen(*wxLIGHT_GREY_PEN); dc.SetBrush(*wxWHITE_BRUSH); - dc.DrawRectangle(position, 0, 7, h); + if ( orient == wxVERTICAL ) + dc.DrawRectangle(position, 0, 7, size.y); + else + dc.DrawRectangle(0, position, size.x, 7); }