Fixed: no enum type was generated for replaced enumerations
This commit is contained in:
parent
3d5c2943fc
commit
f6b4267a5e
2
.gitignore
vendored
2
.gitignore
vendored
@ -4,3 +4,5 @@ Units/__history/
|
|||||||
bin/
|
bin/
|
||||||
lib/
|
lib/
|
||||||
__history/
|
__history/
|
||||||
|
|
||||||
|
*.stat
|
||||||
|
@ -459,6 +459,7 @@ var
|
|||||||
propertyItem: TXMLDataBindingSimpleProperty;
|
propertyItem: TXMLDataBindingSimpleProperty;
|
||||||
newMembers: TList<TXMLDataBindingEnumerationMember>;
|
newMembers: TList<TXMLDataBindingEnumerationMember>;
|
||||||
newPropertyItem: TXMLDataBindingItemProperty;
|
newPropertyItem: TXMLDataBindingItemProperty;
|
||||||
|
targetSchema: TXMLDataBindingSchema;
|
||||||
|
|
||||||
begin
|
begin
|
||||||
for itemIndex := 0 to Pred(Hints.Enumerations.Count) do
|
for itemIndex := 0 to Pred(Hints.Enumerations.Count) do
|
||||||
@ -491,6 +492,10 @@ begin
|
|||||||
if propertyItem.DataType.Name = 'string' then
|
if propertyItem.DataType.Name = 'string' then
|
||||||
begin
|
begin
|
||||||
enumerationItem := TXMLDataBindingEnumeration.Create(Self, schemaItem.SchemaItem, nil, schemaItem.Name);
|
enumerationItem := TXMLDataBindingEnumeration.Create(Self, schemaItem.SchemaItem, nil, schemaItem.Name);
|
||||||
|
|
||||||
|
if FindSchema(enumeration.Schema, targetSchema) then
|
||||||
|
targetSchema.AddItem(enumerationItem);
|
||||||
|
|
||||||
newPropertyItem := TXMLDataBindingItemProperty.Create(Self, propertyItem.SchemaItem, propertyItem.Name, enumerationItem);
|
newPropertyItem := TXMLDataBindingItemProperty.Create(Self, propertyItem.SchemaItem, propertyItem.Name, enumerationItem);
|
||||||
|
|
||||||
newMembers := GetNewMembers(enumerationItem, enumeration);
|
newMembers := GetNewMembers(enumerationItem, enumeration);
|
||||||
|
@ -139,7 +139,6 @@ type
|
|||||||
procedure ReplaceItem(const AOldItem, ANewItem: TXMLDataBindingItem; ARemoveOnly: Boolean); override;
|
procedure ReplaceItem(const AOldItem, ANewItem: TXMLDataBindingItem; ARemoveOnly: Boolean); override;
|
||||||
|
|
||||||
procedure AddInclude(ASchema: TXMLDataBindingSchema);
|
procedure AddInclude(ASchema: TXMLDataBindingSchema);
|
||||||
procedure AddItem(AItem: TXMLDataBindingItem);
|
|
||||||
procedure InsertItem(AItem, AAfter: TXMLDataBindingItem);
|
procedure InsertItem(AItem, AAfter: TXMLDataBindingItem);
|
||||||
|
|
||||||
property ItemsGenerated: Boolean read FItemsGenerated write FItemsGenerated;
|
property ItemsGenerated: Boolean read FItemsGenerated write FItemsGenerated;
|
||||||
@ -147,6 +146,8 @@ type
|
|||||||
constructor Create(AOwner: TXMLDataBindingGenerator);
|
constructor Create(AOwner: TXMLDataBindingGenerator);
|
||||||
destructor Destroy; override;
|
destructor Destroy; override;
|
||||||
|
|
||||||
|
procedure AddItem(AItem: TXMLDataBindingItem);
|
||||||
|
|
||||||
property TargetNamespace: String read GetTargetNamespace;
|
property TargetNamespace: String read GetTargetNamespace;
|
||||||
|
|
||||||
property IncludeCount: Integer read GetIncludeCount;
|
property IncludeCount: Integer read GetIncludeCount;
|
||||||
|
@ -1,10 +0,0 @@
|
|||||||
[Stats]
|
|
||||||
EditorSecs=92
|
|
||||||
DesignerSecs=13
|
|
||||||
InspectorSecs=1
|
|
||||||
CompileSecs=1741
|
|
||||||
OtherSecs=40
|
|
||||||
StartTime=09/04/2020 10:52:32
|
|
||||||
RealKeys=0
|
|
||||||
EffectiveKeys=0
|
|
||||||
DebugSecs=71
|
|
Loading…
Reference in New Issue
Block a user