]>
Commit | Line | Data |
---|---|---|
fb896a32 DE |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: wx/cocoa/dcmemory.h | |
938156b2 | 3 | // Purpose: wxMemoryDCImpl class |
fb896a32 DE |
4 | // Author: David Elliott |
5 | // Modified by: | |
6 | // Created: 2003/03/16 | |
fb896a32 | 7 | // Copyright: (c) 2003 David Elliott |
1b88201f | 8 | // Licence: wxWindows licence |
fb896a32 DE |
9 | ///////////////////////////////////////////////////////////////////////////// |
10 | ||
11 | #ifndef __WX_COCOA_DCMEMORY_H__ | |
12 | #define __WX_COCOA_DCMEMORY_H__ | |
13 | ||
938156b2 | 14 | #include "wx/cocoa/dc.h" |
fb896a32 | 15 | |
938156b2 DE |
16 | #include "wx/dcmemory.h" |
17 | ||
53a2db12 | 18 | class WXDLLIMPEXP_CORE wxMemoryDCImpl: public wxCocoaDCImpl |
fb896a32 | 19 | { |
938156b2 | 20 | DECLARE_DYNAMIC_CLASS(wxMemoryDCImpl) |
fea35690 | 21 | |
fb896a32 | 22 | public: |
938156b2 DE |
23 | wxMemoryDCImpl(wxMemoryDC *owner) |
24 | : wxCocoaDCImpl(owner) | |
25 | { Init(); } | |
26 | wxMemoryDCImpl(wxMemoryDC *owner, wxBitmap& bitmap) | |
27 | : wxCocoaDCImpl(owner) | |
28 | { Init(); | |
29 | owner->SelectObject(bitmap); | |
30 | } | |
31 | wxMemoryDCImpl(wxMemoryDC *owner, wxDC *dc ); // Create compatible DC | |
32 | virtual ~wxMemoryDCImpl(void); | |
fea35690 | 33 | |
fb896a32 | 34 | virtual void DoGetSize(int *width, int *height) const; |
fea35690 VZ |
35 | virtual void DoSelect(const wxBitmap& bitmap); |
36 | ||
28f3fe51 DE |
37 | protected: |
38 | wxBitmap m_selectedBitmap; | |
39 | WX_NSImage m_cocoaNSImage; | |
fe8f7943 DE |
40 | // DC stack |
41 | virtual bool CocoaLockFocus(); | |
42 | virtual bool CocoaUnlockFocus(); | |
3e21fc05 | 43 | virtual bool CocoaGetBounds(void *rectData); |
2c23fe91 DE |
44 | // Blitting |
45 | virtual bool CocoaDoBlitOnFocusedDC(wxCoord xdest, wxCoord ydest, | |
46 | wxCoord width, wxCoord height, wxCoord xsrc, wxCoord ysrc, | |
89efaf2b | 47 | wxRasterOperationMode logicalFunc, bool useMask, wxCoord xsrcMask, wxCoord ysrcMask); |
fea35690 VZ |
48 | |
49 | private: | |
50 | void Init(); | |
fb896a32 DE |
51 | }; |
52 | ||
1b88201f WS |
53 | #endif |
54 | // __WX_COCOA_DCMEMORY_H__ |