wxASSERT_MSG( !HasClientUntypedData(),
wxT("can't have both object and void client data") );
+ wxCHECK_RET( IsValid(n), "Invalid index passed to SetClientObject()" );
+
if ( HasClientObjectData() )
{
wxClientData * clientDataOld
wxCHECK_MSG( HasClientObjectData(), NULL,
wxT("this window doesn't have object client data") );
+ wxCHECK_MSG( IsValid(n), NULL,
+ "Invalid index passed to GetClientObject()" );
+
return static_cast<wxClientData *>(DoGetItemClientData(n));
}
wxASSERT_MSG( HasClientUntypedData(),
wxT("can't have both object and void client data") );
+ wxCHECK_RET( IsValid(n), "Invalid index passed to SetClientData()" );
+
DoSetItemClientData(n, data);
}
wxCHECK_MSG( HasClientUntypedData(), NULL,
wxT("this window doesn't have void client data") );
+ wxCHECK_MSG( IsValid(n), NULL,
+ "Invalid index passed to GetClientData()" );
+
return DoGetItemClientData(n);
}