Fixed bug: wxPGProperty::SetName() crashed if it was called before property was added to grid (fixes #11111)

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@61673 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Jaakko Salli
2009-08-16 15:17:50 +00:00
parent 95bd284e77
commit 5fdb635092
3 changed files with 10 additions and 6 deletions

View File

@@ -613,6 +613,15 @@ bool wxPGProperty::IsSomeParent( wxPGProperty* candidate ) const
return false;
}
void wxPGProperty::SetName( const wxString& newName )
{
wxPropertyGrid* pg = GetGrid();
if ( pg )
pg->SetPropertyName(this, newName);
else
DoSetName(newName);
}
wxString wxPGProperty::GetName() const
{