diff options
Diffstat (limited to 'examples/apps')
-rw-r--r-- | examples/apps/uidesigner/vfdprops.pas | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/examples/apps/uidesigner/vfdprops.pas b/examples/apps/uidesigner/vfdprops.pas index 37daf557..e4bf9912 100644 --- a/examples/apps/uidesigner/vfdprops.pas +++ b/examples/apps/uidesigner/vfdprops.pas @@ -225,8 +225,14 @@ begin end; function TPropertyInteger.GetPropertySource(wg: TfpgWidget; const ident: string): string; +var + PropInfo: PPropInfo; begin - Result := ident + Name + ' := ' + IntToStr(GetOrdProp(wg, Name)) + ';' + LineEnding; + PropInfo := GetPropInfo(wg.ClassType, Name); + if PropInfo^.Default <> GetOrdProp(wg, Name) then + Result := ident + Name + ' := ' + IntToStr(GetOrdProp(wg, Name)) + ';' + LineEnding + else + Result := ''; end; function TPropertyInteger.GetValueText(wg: TfpgWidget): string; |