When wxPGProperty is un-attached from wxPropertyGrid, keep its 'default' cell references invalid/NULL (fixes #12552)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@65788 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -306,6 +306,13 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
// Used mostly internally to figure out if this cell is supposed
|
||||
// to have default values when attached to a grid.
|
||||
bool IsInvalid() const
|
||||
{
|
||||
return ( m_refData == NULL );
|
||||
}
|
||||
|
||||
private:
|
||||
virtual wxObjectRefData *CreateRefData() const
|
||||
{ return new wxPGCellData(); }
|
||||
@@ -2395,6 +2402,11 @@ protected:
|
||||
|
||||
void ClearFlag( FlagType flag ) { m_flags &= ~(flag); }
|
||||
|
||||
// Called when the property is being removed from the grid and/or
|
||||
// page state (but *not* when it is also deleted).
|
||||
void OnDetached(wxPropertyGridPageState* state,
|
||||
wxPropertyGrid* propgrid);
|
||||
|
||||
// Call after fixed sub-properties added/removed after creation.
|
||||
// if oldSelInd >= 0 and < new max items, then selection is
|
||||
// moved to it.
|
||||
|
Reference in New Issue
Block a user