]> git.saurik.com Git - wxWidgets.git/blame - include/wx/msw/dcclient.h
Remove wxRTTI macro for wxComboBox from Motif port.
[wxWidgets.git] / include / wx / msw / dcclient.h
CommitLineData
2bda0e17 1/////////////////////////////////////////////////////////////////////////////
80fdcdb9 2// Name: wx/msw/dcclient.h
2bda0e17
KB
3// Purpose: wxClientDC class
4// Author: Julian Smart
5// Modified by:
6// Created: 01/02/97
7// RCS-ID: $Id$
371a5b4e 8// Copyright: (c) Julian Smart
65571936 9// Licence: wxWindows licence
2bda0e17
KB
10/////////////////////////////////////////////////////////////////////////////
11
bbcdf8bc
JS
12#ifndef _WX_DCCLIENT_H_
13#define _WX_DCCLIENT_H_
2bda0e17 14
3a5ffa81
VZ
15// ----------------------------------------------------------------------------
16// headers
17// ----------------------------------------------------------------------------
18
2bda0e17 19#include "wx/dc.h"
888dde65
RR
20#include "wx/msw/dc.h"
21#include "wx/dcclient.h"
2bda0e17 22
ddc8faa9 23class wxPaintDCInfo;
3a5ffa81
VZ
24
25// ----------------------------------------------------------------------------
26// DC classes
27// ----------------------------------------------------------------------------
28
53a2db12 29class WXDLLIMPEXP_CORE wxWindowDCImpl : public wxMSWDCImpl
2bda0e17 30{
3a5ffa81 31public:
7ba4fbeb 32 // default ctor
888dde65 33 wxWindowDCImpl( wxDC *owner );
2bda0e17 34
3a5ffa81 35 // Create a DC corresponding to the whole window
888dde65 36 wxWindowDCImpl( wxDC *owner, wxWindow *win );
2bda0e17 37
512cfcc3
PC
38 virtual void DoGetSize(int *width, int *height) const;
39
7ba4fbeb 40protected:
3103e8a9 41 // initialize the newly created DC
7ba4fbeb
VZ
42 void InitDC();
43
888dde65 44 DECLARE_CLASS(wxWindowDCImpl)
c0c133e1 45 wxDECLARE_NO_COPY_CLASS(wxWindowDCImpl);
2bda0e17
KB
46};
47
53a2db12 48class WXDLLIMPEXP_CORE wxClientDCImpl : public wxWindowDCImpl
2bda0e17 49{
3a5ffa81 50public:
7ba4fbeb 51 // default ctor
888dde65 52 wxClientDCImpl( wxDC *owner );
2bda0e17 53
3a5ffa81 54 // Create a DC corresponding to the client area of the window
888dde65 55 wxClientDCImpl( wxDC *owner, wxWindow *win );
2bda0e17 56
888dde65 57 virtual ~wxClientDCImpl();
1e6feb95 58
512cfcc3
PC
59 virtual void DoGetSize(int *width, int *height) const;
60
1e6feb95
VZ
61protected:
62 void InitDC();
63
888dde65 64 DECLARE_CLASS(wxClientDCImpl)
c0c133e1 65 wxDECLARE_NO_COPY_CLASS(wxClientDCImpl);
2bda0e17
KB
66};
67
53a2db12 68class WXDLLIMPEXP_CORE wxPaintDCImpl : public wxClientDCImpl
2bda0e17 69{
3a5ffa81 70public:
888dde65 71 wxPaintDCImpl( wxDC *owner );
2bda0e17 72
3a5ffa81 73 // Create a DC corresponding for painting the window in OnPaint()
888dde65 74 wxPaintDCImpl( wxDC *owner, wxWindow *win );
2bda0e17 75
888dde65 76 virtual ~wxPaintDCImpl();
2bda0e17 77
63da7df7
JS
78 // find the entry for this DC in the cache (keyed by the window)
79 static WXHDC FindDCInCache(wxWindow* win);
80
ddc8faa9
VZ
81 // This must be called by the code handling WM_PAINT to remove the DC
82 // cached for this window for the duration of this message processing.
83 static void EndPaint(wxWindow *win);
2bda0e17 84
ddc8faa9
VZ
85protected:
86 // Find the DC for this window in the cache, return NULL if not found.
87 static wxPaintDCInfo *FindInCache(wxWindow* win);
7ba4fbeb 88
888dde65 89 DECLARE_CLASS(wxPaintDCImpl)
c0c133e1 90 wxDECLARE_NO_COPY_CLASS(wxPaintDCImpl);
2bda0e17
KB
91};
92
c6151f2a
JS
93/*
94 * wxPaintDCEx
95 * This class is used when an application sends an HDC with the WM_PAINT
96 * message. It is used in HandlePaint and need not be used by an application.
97 */
98
53a2db12 99class WXDLLIMPEXP_CORE wxPaintDCEx : public wxPaintDC
c6151f2a
JS
100{
101public:
102 wxPaintDCEx(wxWindow *canvas, WXHDC dc);
03647350 103
c6151f2a 104 DECLARE_CLASS(wxPaintDCEx)
c0c133e1 105 wxDECLARE_NO_COPY_CLASS(wxPaintDCEx);
c6151f2a
JS
106};
107
2bda0e17 108#endif
bbcdf8bc 109 // _WX_DCCLIENT_H_