X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/1425eca550ca78f6d0824e50376d763aff17242d..a1e92028b314fb19ecdc2756fa2601603e7f6607:/samples/propgrid/sampleprops.cpp diff --git a/samples/propgrid/sampleprops.cpp b/samples/propgrid/sampleprops.cpp index 5791ebae83..e7c29c9d19 100644 --- a/samples/propgrid/sampleprops.cpp +++ b/samples/propgrid/sampleprops.cpp @@ -67,11 +67,9 @@ wxFontDataProperty::wxFontDataProperty( const wxString& label, const wxString& n // (instead of calling SetValue) in derived (wxObject) properties. m_value_wxFontData << value; - SetParentalType(wxPG_PROP_AGGREGATE); - // Add extra children. - AddChild( new wxColourProperty(_("Colour"), wxPG_LABEL, - fontData.GetColour() ) ); + AddPrivateChild( new wxColourProperty(_("Colour"), wxPG_LABEL, + fontData.GetColour() ) ); } wxFontDataProperty::~wxFontDataProperty () { } @@ -199,9 +197,8 @@ wxSizeProperty::wxSizeProperty( const wxString& label, const wxString& name, const wxSize& value) : wxPGProperty(label,name) { SetValueI(value); - SetParentalType(wxPG_PROP_AGGREGATE); - AddChild( new wxIntProperty(wxT("Width"),wxPG_LABEL,value.x) ); - AddChild( new wxIntProperty(wxT("Height"),wxPG_LABEL,value.y) ); + AddPrivateChild( new wxIntProperty(wxT("Width"),wxPG_LABEL,value.x) ); + AddPrivateChild( new wxIntProperty(wxT("Height"),wxPG_LABEL,value.y) ); } wxSizeProperty::~wxSizeProperty() { } @@ -236,9 +233,8 @@ wxPointProperty::wxPointProperty( const wxString& label, const wxString& name, const wxPoint& value) : wxPGProperty(label,name) { SetValueI(value); - SetParentalType(wxPG_PROP_AGGREGATE); - AddChild( new wxIntProperty(wxT("X"),wxPG_LABEL,value.x) ); - AddChild( new wxIntProperty(wxT("Y"),wxPG_LABEL,value.y) ); + AddPrivateChild( new wxIntProperty(wxT("X"),wxPG_LABEL,value.x) ); + AddPrivateChild( new wxIntProperty(wxT("Y"),wxPG_LABEL,value.y) ); } wxPointProperty::~wxPointProperty() { }