Exemplo n.º 1
0
        private ExpandingNode addSubInterface(EditInterface subInterface)
        {
            ExpandingNode node = new ExpandingNode(subInterface, childArea, uiCallback, this);

            children.Add(node);
            node.changeWidth(childArea.Width);
            layout();
            return(node);
        }
Exemplo n.º 2
0
        public ExpandingNode(EditInterface editInterface, Widget parentWidget, GuiFrameworkUICallback uiCallback, ExpandingNode parent = null)
            : base("Anomalous.GuiFramework.Editor.GUI.ExpandingEditInterfaceViewer.ExpandingNode.layout")
        {
            this.uiCallback = uiCallback;
            this.parent     = parent;

            widget.attachToWidget(parentWidget);
            defaultHeight = widget.Height;

            caption         = (TextBox)widget.findWidget("Caption");
            caption.Caption = editInterface.getName();

            expandButton = new CheckButton((Button)widget.findWidget("ExpandButton"));
            expandButton.CheckedChanged += new MyGUIEvent(expandButton_CheckedChanged);

            childArea      = widget.findWidget("ChildArea");
            propertiesForm = new PropertiesForm(childArea, uiCallback);
            propertiesForm.LayoutChanged += propertiesForm_LayoutChanged;

            this.editInterface = editInterface;
            editInterface.OnSubInterfaceAdded   += editInterface_OnSubInterfaceAdded;
            editInterface.OnSubInterfaceRemoved += editInterface_OnSubInterfaceRemoved;
        }
Exemplo n.º 3
0
 void rootNode_LayoutChanged(ExpandingNode obj)
 {
     scrollView.CanvasSize = new IntSize2(scrollView.ViewCoord.width, rootNode.Height);
 }