+void wxPGProperty::OnDetached(wxPropertyGridPageState* WXUNUSED(state),
+ wxPropertyGrid* propgrid)
+{
+ if ( propgrid )
+ {
+ const wxPGCell& propDefCell = propgrid->GetPropertyDefaultCell();
+ const wxPGCell& catDefCell = propgrid->GetCategoryDefaultCell();
+
+ // Make default cells invalid
+ for ( unsigned int i=0; i<m_cells.size(); i++ )
+ {
+ wxPGCell& cell = m_cells[i];
+ if ( cell.IsSameAs(propDefCell) ||
+ cell.IsSameAs(catDefCell) )
+ {
+ cell.UnRef();
+ }
+ }
+ }
+}
+