From 17043551f975aa007e54d5f9a6211fbf5685268f Mon Sep 17 00:00:00 2001 From: Mark van Renswoude Date: Thu, 9 Apr 2020 10:55:19 +0200 Subject: [PATCH] Fixed bug in Def properties using the original element name instead of the generated property name --- Units/DelphiXMLDataBindingResources.pas | 4 +- X2XMLDataBinding.dproj | 306 +++++++++++++----------- X2XMLDataBinding.res | Bin 163348 -> 163832 bytes X2XMLDataBinding.stat | 10 + 4 files changed, 173 insertions(+), 147 deletions(-) create mode 100644 X2XMLDataBinding.stat diff --git a/Units/DelphiXMLDataBindingResources.pas b/Units/DelphiXMLDataBindingResources.pas index 2f093ae..12fbda1 100644 --- a/Units/DelphiXMLDataBindingResources.pas +++ b/Units/DelphiXMLDataBindingResources.pas @@ -179,8 +179,8 @@ const PropertyImplMethodGetOptionalOrDefault = 'function TXML%:s.%:sDef(const ADefaultValue: %:s): %:s;' + CrLf + 'begin' + CrLf + - ' if GetHas%:s then' + CrLf + - ' Result := Get%:s' + CrLf + + ' if GetHas%:s then' + CrLf + + ' Result := Get%:s' + CrLf + ' else' + CrLf + ' Result := ADefaultValue;' + CrLf + 'end;' + CrLf + diff --git a/X2XMLDataBinding.dproj b/X2XMLDataBinding.dproj index 38a2443..abf50cf 100644 --- a/X2XMLDataBinding.dproj +++ b/X2XMLDataBinding.dproj @@ -1,145 +1,161 @@ - - - {983dfcaf-23ca-48a0-a147-d96769428a71} - X2XMLDataBinding.dpr - Debug - DCC32 - bin\X2XMLDataBinding.exe - VCL - 13.4 - True - Build - Win32 - 3 - Application - - - true - - - true - Base - true - - - true - Base - true - - - true - Base - true - - - true - Cfg_2 - true - true - - - bin - X2XMLDataBinding_Icon.ico - Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;System;Xml;Data;Datasnap;Web;Soap;Winapi;Xml.Win;System.Win;$(DCC_Namespace) - CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments= - lib - 1043 - $(BDS)\bin\default_app.manifest - - - true - Data.Win;Datasnap.Win;Web.Win;Soap.Win;$(DCC_Namespace) - bin64 - lib64 - 1033 - - - Data.Win;Datasnap.Win;Web.Win;Soap.Win;Bde;$(DCC_Namespace) - "P:\updateserver\xsd\ads111.xsd" - 1033 - - - 7.0 - 3 - DEBUG;$(DCC_Define) - Lib - Lib - - - true - 1033 - - - Delphi.Personality.12 - - - - - False - True - False - "P:\updateserver\xsd\ads111.xsd" - - - False - False - 1 - 0 - 0 - 0 - False - False - False - False - False - 1043 - 1252 - - - - - 1.0.0.0 - - - - - - 1.0.0.0 - - - - X2XMLDataBinding.dpr - - - - True - True - - - 12 - - - - - MainSource - - -
MainForm
-
- - - - - - - - - Cfg_2 - Base - - - Base - -
- -
+ + + {983dfcaf-23ca-48a0-a147-d96769428a71} + X2XMLDataBinding.dpr + Debug + DCC32 + bin\X2XMLDataBinding.exe + VCL + 18.2 + True + Build + Win32 + 3 + Application + + + true + + + true + Base + true + + + true + Base + true + + + true + Base + true + + + true + Cfg_2 + true + true + + + true + Cfg_2 + true + true + + + bin + X2XMLDataBinding_Icon.ico + Vcl;Vcl.Imaging;Vcl.Touch;Vcl.Samples;Vcl.Shell;System;Xml;Data;Datasnap;Web;Soap;Winapi;Xml.Win;System.Win;$(DCC_Namespace) + CompanyName=;FileDescription=;FileVersion=1.0.0.0;InternalName=;LegalCopyright=;LegalTrademarks=;OriginalFilename=;ProductName=;ProductVersion=1.0.0.0;Comments= + lib + 1043 + $(BDS)\bin\default_app.manifest + X2XMLDataBinding + + + Data.Win;Datasnap.Win;Web.Win;Soap.Win;Bde;$(DCC_Namespace) + "P:\updateserver\xsd\ads111.xsd" + 1033 + $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png + $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png + + + true + Data.Win;Datasnap.Win;Web.Win;Soap.Win;$(DCC_Namespace) + bin64 + lib64 + 1033 + $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_44.png + $(BDS)\bin\Artwork\Windows\UWP\delphi_UwpDefault_150.png + + + 7.0 + 3 + DEBUG;$(DCC_Define) + Lib + Lib + + + true + 1033 + Debug + + + Debug + + + Delphi.Personality.12 + + + + + False + True + False + "P:\updateserver\xsd\ads111.xsd" + + + False + False + 1 + 0 + 0 + 0 + False + False + False + False + False + 1043 + 1252 + + + + + 1.0.0.0 + + + + + + 1.0.0.0 + + + + X2XMLDataBinding.dpr + + + + True + True + + + 12 + + + + + MainSource + + +
MainForm
+
+ + + + + + + + + Cfg_2 + Base + + + Base + +
+ + +
diff --git a/X2XMLDataBinding.res b/X2XMLDataBinding.res index 2f784beceb7bbfdeda9cef2caa30eaef5a507345..f1c0ad08d3a578d74f67ce3afc66debecef7a18a 100644 GIT binary patch delta 910 zcmbu7O^Vb&6vr_LlEy{^moBQaaQ7xvsj8$RnT7!u(<=o<*Hx)145T}uD?Q_UH0{D8 z3}opM+;{*_;KoacCvYKXrIm&edZAOR_wncbUOoO-Kf>=n!?*8leGI;y2Ong zchQ@9y>O4Eo1f7B*+nq9L!;?SzE(39Ig#0UMcm(C2M^-kQ{&xOpBHhrT)A$xu#LwTWixMOSE;J@ z*#7fn5N)oN4o*lkMdMLe$hNJk(rcT=wh$H*fETX~nms|v)XgcX7J3jEhrAZKRogbp z4%udjUinsY>d?!|brJ!1au^nW6h=RNj%NBWx-bbQWW#s{gtHVFEjdVT4PY#^F@|bt z@j8nCo1g7xQ%b5rzV%Du)eY zjDV7P2|CR+lT4mR>?| z%8rlPe<*V!jh;~=xa5H{uPF2ROqwGe zMLA~&BhHlIp{!A+ASC5%(C(Rs<*l{i#0x1oh4hl&LOIdxcfFq7v28+vjvv%ULzhhw zccR7jYiKMu0V%m~1i9%`1w=)_#P#1cp%bQJ3aIwS#i z2}lM0xu8=T!UW{7RTvrCYqSa{L%aI9&d|<9C0Ztkt$%6De6h75f-NNysm3heS`=H= Mr|4p