]> git.saurik.com Git - wxWidgets.git/blobdiff - samples/propgrid/sampleprops.cpp
document that a valid image list is required for item dragging under MSW (see #4390)
[wxWidgets.git] / samples / propgrid / sampleprops.cpp
index 5791ebae837293d458478d38d7bec75872f66dbe..e7c29c9d190c491edda1afbc2daca9aebbcf0408 100644 (file)
@@ -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() { }