Removed dysfunctional wxPGPropery::PrepareValueForDialogEditing(); Replaced its functionality with wxPropertyGrid::GetPendingEditedValue(); Added wxPropertyGrid::PerformValidation() flags so it can be called in generic context.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56169 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Jaakko Salli
2008-10-08 18:15:10 +00:00
parent 483b6cf0d4
commit 9b5bafcf38
9 changed files with 110 additions and 93 deletions

View File

@@ -131,11 +131,10 @@ bool wxFontDataProperty::OnEvent( wxPropertyGrid* propgrid,
{
if ( propgrid->IsMainButtonEvent(event) )
{
// Update value from last minute changes
PrepareValueForDialogEditing(propgrid);
wxVariant useValue = propgrid->GetPendingEditedValue();
wxFontData fontData;
fontData << m_value_wxFontData;
fontData << useValue;
fontData.SetInitialFont(fontData.GetChosenFont());
@@ -554,10 +553,10 @@ bool wxArrayDoubleProperty::OnEvent( wxPropertyGrid* propgrid,
{
if ( propgrid->IsMainButtonEvent(event) )
{
wxArrayDouble& value = wxArrayDoubleRefFromVariant(m_value);
// Update the value in case of last minute changes
PrepareValueForDialogEditing(propgrid);
wxVariant useValue = propgrid->GetPendingEditedValue();
wxArrayDouble& value = wxArrayDoubleRefFromVariant(useValue);
// Create editor dialog.
wxArrayDoubleEditorDialog dlg;