DXScene4.42在XE2 Update3中的Bug修复
DXScene4.42控件在XE2 Update3中CheckBox和RedioButton都出现不能显示IsChecked的情况,经过分析其代码,原因出在XE2的RTTI和之前版本有所不同,GetPropInfo方法获取属性信息的时候,不兼容以前的所有情况。需要修改一下,童鞋们可以打开“dx_vgcore.pas”找到 procedure TvxColorAnimation.ProcessAnimation;方法,将下面代码:
{ is string prop }
if GetPropInfo(FInstance.ClassInfo, FPath, [tkString, tkLString, tkWString{$IFDEF FPC},tkAString{$ENDIF}{$IFDEF KS_COMPILER11_UP}, tkUString{$ENDIF}]) <> nil then
SetStrProp(FInstance, FPath, vgColorToStr(vgInterpolateColor(FStartColor, FStopColor, NormalizedTime)));
{ is int prop }
if GetPropInfo(FInstance.ClassInfo, FPath, [tkInteger]) <> nil then
SetOrdProp(FInstance, FPath, vgInterpolateColor(FStartColor, FStopColor, NormalizedTime));
修改成:
SetStrProp(FInstance, FPath, vgColorToStr(vgInterpolateColor(FStartColor, FStopColor, NormalizedTime)));
即可。