Slight reorg of last change

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@53037 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Robin Dunn 2008-04-06 02:13:08 +00:00
parent e203535ff0
commit 247ca48fec

View File

@ -699,26 +699,22 @@ OSStatus wxMacDataViewDataBrowserListViewControl::DataBrowserGetSetItemDataProc(
// variable definition and initialization:
wxVariant modifiedData(true);
if (dataViewCtrlPtr->GetModel()->SetValue(modifiedData, dvItem, col))
{
dataViewCtrlPtr->GetModel()->ValueChanged(dvItem, col);
if (dataViewCtrlPtr->GetModel()->SetValue(modifiedData, dvItem, col) &&
dataViewCtrlPtr->GetModel()->ValueChanged(dvItem, col))
return noErr;
}
else
return errDataBrowserNotConfigured;
return errDataBrowserInvalidPropertyData;
} /* if */
else if (buttonValue == kThemeButtonOff)
{
// variable definition and initialization:
wxVariant modifiedData(false);
if (dataViewCtrlPtr->GetModel()->SetValue(modifiedData, dvItem, col))
{
dataViewCtrlPtr->GetModel()->ValueChanged(dvItem, col);
if (dataViewCtrlPtr->GetModel()->SetValue(modifiedData, dvItem, col) &&
dataViewCtrlPtr->GetModel()->ValueChanged(dvItem, col))
return noErr;
}
else
return errDataBrowserNotConfigured;
return errDataBrowserInvalidPropertyData;
} /* if */
else
return errDataBrowserInvalidPropertyData;
@ -742,13 +738,11 @@ OSStatus wxMacDataViewDataBrowserListViewControl::DataBrowserGetSetItemDataProc(
#endif
wxVariant modifiedData(modifiedString.AsString());
if (dataViewCtrlPtr->GetModel()->SetValue(modifiedData, dvItem, col))
{
dataViewCtrlPtr->GetModel()->ValueChanged(dvItem, col);
return noErr;
}
else
return errDataBrowserNotConfigured;
if (dataViewCtrlPtr->GetModel()->SetValue(modifiedData, dvItem, col) &&
dataViewCtrlPtr->GetModel()->ValueChanged(dvItem, col))
return noErr;
else
return errDataBrowserInvalidPropertyData;
} /* if */
else
return errorStatus;