diff options
| author | jpbruyere <jp.bruyere@hotmail.com> | 2015-12-23 18:24:28 +0100 |
|---|---|---|
| committer | jpbruyere <jp.bruyere@hotmail.com> | 2015-12-23 18:24:28 +0100 |
| commit | b6fccb76291456485af671082b58e18fe37d395e (patch) | |
| tree | 5f28a86d4a66df545e5c1e82eb75fa091d60ae86 /src/GraphicObjects/TemplatedControl.cs | |
| parent | 8678a1351e90c94741661a83efefdce8e7493b01 (diff) | |
Prevent multiple template loading
debug group and stack layouting , onLayoutChanged
divers debug
Diffstat (limited to 'src/GraphicObjects/TemplatedControl.cs')
| -rw-r--r-- | src/GraphicObjects/TemplatedControl.cs | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/GraphicObjects/TemplatedControl.cs b/src/GraphicObjects/TemplatedControl.cs index 4ab3a362..fc1a61f2 100644 --- a/src/GraphicObjects/TemplatedControl.cs +++ b/src/GraphicObjects/TemplatedControl.cs @@ -96,8 +96,8 @@ namespace go protected override void loadDefaultValues () { - if (child == null)//trigger loading of default template if child is empty - loadTemplate (); +// if (child == null)//trigger loading of default template if child is empty +// loadTemplate (); base.loadDefaultValues (); } public override GraphicObject FindByName (string nameToFind) @@ -159,15 +159,18 @@ namespace go xr.Read ();//go close tag xr.Read ();//Template close tag break; - } else { - xr.ReadInnerXml (); - } + } else + xr.ReadInnerXml (); } } } else loadTemplate (Interface.Load (template, this)); - + if (this.child == null) { + loadTemplate (); + loadDefaultValues (); + } + //normal xml read using (XmlReader xr = new XmlTextReader (tmp, XmlNodeType.Element, null)) { xr.Read (); |