/// <summary> /// Event handler called when decorator initialization is complete for JunctionShape. Adds decorator mappings for this shape or connector. /// </summary> public static void OnDecoratorsInitialized(object sender, global::System.EventArgs e) { ComponentShapeDecoratorMap.OnDecoratorsInitialized(sender, e); DslDiagrams::ShapeElement shape = (DslDiagrams::ShapeElement)sender; DslDiagrams::AssociatedPropertyInfo propertyInfo; propertyInfo = new DslDiagrams::AssociatedPropertyInfo(global::Microsoft.Example.Circuits.NamedElement.NameDomainPropertyId); DslDiagrams::ShapeElement.FindDecorator(shape.Decorators, "NameDecorator").AssociateValueWith(shape.Store, propertyInfo); }
/// <summary> /// Event handler called when decorator initialization is complete for CapacitorShape. Adds decorator mappings for this shape or connector. /// </summary> public static void OnDecoratorsInitialized(object sender, global::System.EventArgs e) { ComponentShapeDecoratorMap.OnDecoratorsInitialized(sender, e); DslDiagrams::ShapeElement shape = (DslDiagrams::ShapeElement)sender; DslDiagrams::AssociatedPropertyInfo propertyInfo; propertyInfo = new DslDiagrams::AssociatedPropertyInfo(global::Microsoft.Example.Circuits.NamedElement.NameDomainPropertyId); DslDiagrams::ShapeElement.FindDecorator(shape.Decorators, "NameDecorator").AssociateValueWith(shape.Store, propertyInfo); propertyInfo = new DslDiagrams::AssociatedPropertyInfo(global::Microsoft.Example.Circuits.Capacitor.IsPolarDomainPropertyId); propertyInfo.FilteringValues.Add("False"); DslDiagrams::ShapeElement.FindDecorator(shape.Decorators, "NonPolarImage").AssociateVisibilityWith(shape.Store, propertyInfo); propertyInfo = new DslDiagrams::AssociatedPropertyInfo(global::Microsoft.Example.Circuits.Capacitor.IsPolarDomainPropertyId); propertyInfo.FilteringValues.Add("True"); DslDiagrams::ShapeElement.FindDecorator(shape.Decorators, "PolarImage").AssociateVisibilityWith(shape.Store, propertyInfo); }