]>
git.saurik.com Git - wxWidgets.git/blob - src/mac/carbon/colordlg.cpp
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxColourDialog class. NOTE: you can use the generic class
4 // if you wish, instead of implementing this.
9 // Copyright: (c) AUTHOR
10 // Licence: wxWindows licence
11 /////////////////////////////////////////////////////////////////////////////
14 #pragma implementation "colordlg.h"
17 #include "wx/mac/colordlg.h"
19 #if !USE_SHARED_LIBRARY
20 IMPLEMENT_DYNAMIC_CLASS(wxColourDialog
, wxDialog
)
23 #include "wx/mac/private.h"
29 wxColourDialog::wxColourDialog()
31 m_dialogParent
= NULL
;
34 wxColourDialog::wxColourDialog(wxWindow
*parent
, wxColourData
*data
)
39 bool wxColourDialog::Create(wxWindow
*parent
, wxColourData
*data
)
41 m_dialogParent
= parent
;
48 int wxColourDialog::ShowModal()
51 RGBColor currentColor
= *((RGBColor
*)m_colourData
.dataColour
.GetPixel()) , newColor
;
53 where
.h
= where
.v
= -1;
55 if (GetColor( where
, "\pSelect a new palette color.", ¤tColor
, &newColor
))
57 m_colourData
.dataColour
.Set( (WXCOLORREF
*) &newColor
) ;