Add wxRendererNative::DrawCollapseButton() for use in collapsible pane like controls.
Add a new method that should be used for controls like wxCollapsiblePane. It is implemented natively for wxMSW (Windows Vista+) and provides a generic fallback for other ports and WinXP.
This commit is contained in:
@@ -260,6 +260,17 @@ public:
|
||||
const wxRect& rect,
|
||||
int flags = 0) = 0;
|
||||
|
||||
// draw collapse button
|
||||
//
|
||||
// flags may use wxCONTROL_CHECKED, wxCONTROL_UNDETERMINED and wxCONTROL_CURRENT
|
||||
virtual void DrawCollapseButton(wxWindow *win,
|
||||
wxDC& dc,
|
||||
const wxRect& rect,
|
||||
int flags = 0) = 0;
|
||||
|
||||
// Returns the default size of a collapse button
|
||||
virtual wxSize GetCollapseButtonSize(wxWindow *win, wxDC& dc) = 0;
|
||||
|
||||
// draw rectangle indicating that an item in e.g. a list control
|
||||
// has been selected or focused
|
||||
//
|
||||
@@ -470,6 +481,15 @@ public:
|
||||
int flags = 0)
|
||||
{ m_rendererNative.DrawPushButton( win, dc, rect, flags ); }
|
||||
|
||||
virtual void DrawCollapseButton(wxWindow *win,
|
||||
wxDC& dc,
|
||||
const wxRect& rect,
|
||||
int flags = 0)
|
||||
{ m_rendererNative.DrawCollapseButton(win, dc, rect, flags); }
|
||||
|
||||
virtual wxSize GetCollapseButtonSize(wxWindow *win, wxDC& dc)
|
||||
{ return m_rendererNative.GetCollapseButtonSize(win, dc); }
|
||||
|
||||
virtual void DrawItemSelectionRect(wxWindow *win,
|
||||
wxDC& dc,
|
||||
const wxRect& rect,
|
||||
|
Reference in New Issue
Block a user