1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/msw/colordlg.h
3 // Purpose: wxColourDialog class
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 #ifndef _WX_COLORDLG_H_
13 #define _WX_COLORDLG_H_
16 #include "wx/dialog.h"
17 #include "wx/cmndata.h"
19 // ----------------------------------------------------------------------------
20 // wxColourDialog: dialog for choosing a colours
21 // ----------------------------------------------------------------------------
23 class WXDLLIMPEXP_CORE wxColourDialog
: public wxDialog
26 wxColourDialog() { Init(); }
27 wxColourDialog(wxWindow
*parent
, wxColourData
*data
= NULL
)
34 bool Create(wxWindow
*parent
, wxColourData
*data
= NULL
);
36 wxColourData
& GetColourData() { return m_colourData
; }
38 // override some base class virtuals
39 virtual void SetTitle(const wxString
& title
);
40 virtual wxString
GetTitle() const;
42 virtual int ShowModal();
44 // wxMSW-specific implementation from now on
45 // -----------------------------------------
47 // called from the hook procedure on WM_INITDIALOG reception
48 virtual void MSWOnInitDone(WXHWND hDlg
);
51 // common part of all ctors
54 #if !(defined(__SMARTPHONE__) && defined(__WXWINCE__))
55 virtual void DoGetPosition( int *x
, int *y
) const;
56 virtual void DoGetSize(int *width
, int *height
) const;
57 virtual void DoGetClientSize(int *width
, int *height
) const;
58 virtual void DoMoveWindow(int x
, int y
, int width
, int height
);
59 virtual void DoCentre(int dir
);
60 #endif // !(__SMARTPHONE__ && __WXWINCE__)
62 wxColourData m_colourData
;
65 // indicates that the dialog should be centered in this direction if non 0
66 // (set by DoCentre(), used by MSWOnInitDone())
69 // true if DoMoveWindow() had been called
73 DECLARE_DYNAMIC_CLASS_NO_COPY(wxColourDialog
)
76 #endif // _WX_COLORDLG_H_