示例#1
0
        protected GuiComponent(GuiComponent parent)
        {
            this.Parent = parent;
            Manager     = parent.Manager;

            Position   = parent.GetInnerCanvasTopLeft();
            Dimensions = new GuiDimensions(new Size(), new Size());

            parent.RegisterChildComponent(this);
        }
示例#2
0
 /// <summary>
 /// used in dynamic positioned windows since the position of the parent may be determined after the
 /// calling of this components ctor
 /// </summary>
 public void AdjustWhenParentsReposition()
 {
     Position = Parent.GetInnerCanvasTopLeft() + Parent.Position + RelativePositionToParent;
 }