コード例 #1
0
        public static T Node <T>(this T self, GUINode element) where T : ParentGUINode
        {
            element.parent = self;
            GUICanvas canvas = element.root as GUICanvas;

            if (canvas != null)
            {
                canvas.TreeChange();
            }
            return(self);
        }
コード例 #2
0
        public void GUIRefresh(TreeNode aParent)
        {
            if (Killed)
            {
                return;
            }

            if (aParent != null)
            {
                if (aParent.Nodes.IndexOf(this.GUINode) < 0)
                {
                    if (this.GUINode == null)
                    {
                        ReportSmart.Controls.CRSMessageBox.ShowBox("Meggyilkolt újjáélesztése?");
                    }
                    aParent.Nodes.Add(this.GUINode);
                }
            }
            Sort();

            for (int i = 0; i < _SubItems.Count; i++)
            {
                if (this[i] is CReportFolder)
                {
                    ((CReportFolder)this[i]).GUIRefresh(this.GUINode);
                }
            }

            for (int i = 0; i < _SubItems.Count; i++)
            {
                if (this[i] is CReportFile && GUINode.Nodes.IndexOf(this[i].GUINode) < 0)
                {
                    GUINode.Nodes.Add(this[i].GUINode);
                }
            }

            if (GUIExpanded)
            {
                GUINode.Expand();
            }
            else
            {
                GUINode.Collapse();
            }
        }
コード例 #3
0
        public void GUIRefresh(TreeNode aParent)
        {
            if (Killed)
            {
                return;
            }

            if (aParent != null)
            {
                if (aParent.Nodes.IndexOf(this.GUINode) < 0)
                {
                    aParent.Nodes.Add(this.GUINode);
                }
            }
            Sort();

            for (int i = 0; i < _SubItems.Count; i++)
            {
                if (this[i] is CReportFolder)
                {
                    ((CReportFolder)this[i]).GUIRefresh(this.GUINode);
                }
            }

            for (int i = 0; i < _SubItems.Count; i++)
            {
                if (this[i] is CReportFile && GUINode.Nodes.IndexOf(this[i].GUINode) < 0)
                {
                    GUINode.Nodes.Add(this[i].GUINode);
                }
            }

            if (GUIExpanded)
            {
                GUINode.Expand();
            }
            else
            {
                GUINode.Collapse();
            }
        }