]>
Commit | Line | Data |
---|---|---|
6762286d | 1 | ///////////////////////////////////////////////////////////////////////////// |
80fdcdb9 | 2 | // Name: wx/osx/dcmemory.h |
6762286d SC |
3 | // Purpose: wxMemoryDC class |
4 | // Author: Stefan Csomor | |
5 | // Modified by: | |
6 | // Created: 1998-01-01 | |
6762286d SC |
7 | // Copyright: (c) Stefan Csomor |
8 | // Licence: wxWindows licence | |
9 | ///////////////////////////////////////////////////////////////////////////// | |
10 | ||
11 | #ifndef _WX_DCMEMORY_H_ | |
12 | #define _WX_DCMEMORY_H_ | |
13 | ||
ccd5d46c | 14 | #include "wx/osx/dcclient.h" |
6762286d SC |
15 | |
16 | class WXDLLIMPEXP_CORE wxMemoryDCImpl: public wxPaintDCImpl | |
17 | { | |
18 | public: | |
19 | wxMemoryDCImpl( wxMemoryDC *owner ); | |
20 | wxMemoryDCImpl( wxMemoryDC *owner, wxBitmap& bitmap ); | |
03647350 VZ |
21 | wxMemoryDCImpl( wxMemoryDC *owner, wxDC *dc ); |
22 | ||
6762286d SC |
23 | virtual ~wxMemoryDCImpl(); |
24 | ||
25 | virtual void DoGetSize( int *width, int *height ) const; | |
03647350 | 26 | virtual wxBitmap DoGetAsBitmap(const wxRect *subrect) const |
6762286d SC |
27 | { return subrect == NULL ? GetSelectedBitmap() : GetSelectedBitmap().GetSubBitmap(*subrect); } |
28 | virtual void DoSelect(const wxBitmap& bitmap); | |
29 | ||
30 | virtual const wxBitmap& GetSelectedBitmap() const | |
31 | { return m_selected; } | |
32 | virtual wxBitmap& GetSelectedBitmap() | |
33 | { return m_selected; } | |
03647350 | 34 | |
6762286d SC |
35 | private: |
36 | void Init(); | |
37 | ||
38 | wxBitmap m_selected; | |
03647350 | 39 | |
6762286d | 40 | DECLARE_CLASS(wxMemoryDCImpl) |
c0c133e1 | 41 | wxDECLARE_NO_COPY_CLASS(wxMemoryDCImpl); |
6762286d SC |
42 | }; |
43 | ||
5c6eb3a8 | 44 | #endif |
6762286d | 45 | // _WX_DCMEMORY_H_ |