/// <summary> /// Adds another OverlayElement to this container. /// </summary> /// <param name="element"></param> public virtual void AddChildElement(OverlayElement element) { Debug.Assert(!this.children.ContainsKey(element.Name), string.Format("Child with name '{0}' already defined.", element.Name)); // add to lookup table and list this.children.Add(element.Name, element); // inform this child about his/her parent and zorder element.NotifyParent(this, overlay); element.NotifyZOrder(zOrder + 1); element.NotifyWorldTransforms(xform); element.NotifyViewport(); }
/// <summary> /// Adds another OverlayElement to this container. /// </summary> /// <param name="element"></param> public virtual void AddChildElement( OverlayElement element ) { Debug.Assert( !this.children.ContainsKey( element.Name ), string.Format( "Child with name '{0}' already defined.", element.Name ) ); // add to lookup table and list this.children.Add( element.Name, element ); // inform this child about his/her parent and zorder element.NotifyParent( this, overlay ); element.NotifyZOrder( zOrder + 1 ); element.NotifyWorldTransforms( xform ); element.NotifyViewport(); }