Beispiel #1
0
        CheckListInput addwarningcontrol(int x, int y, CheckListItem item, bool hideforchild = false)
        {
            CheckListInput wrnctl = new CheckListInput(_parent, item);

            wrnctl.ReloadList += wrnctl_ChildAdd;

            wrnctl.Location = new Point(x, y);

            if (hideforchild)
            {
                wrnctl.TXT_text.Visible    = false;
                wrnctl.TXT_desc.Visible    = false;
                wrnctl.CMB_colour1.Visible = false;
                wrnctl.CMB_colour2.Visible = false;
            }

            panel1.Controls.Add(wrnctl);

            y = wrnctl.Bottom;

            if (item.Child != null)
            {
                wrnctl = addwarningcontrol(x += 5, y, item.Child, true);
            }

            return(wrnctl);
        }
        CheckListInput addwarningcontrol(int x, int y, CheckListItem item, bool hideforchild = false)
        {
            CheckListInput wrnctl = new CheckListInput(_parent, item);

            wrnctl.ReloadList += wrnctl_ChildAdd;

            wrnctl.Location = new Point(x, y);

            if (hideforchild)
            {
                wrnctl.TXT_text.Visible = false;
                wrnctl.TXT_desc.Visible = false;
                wrnctl.CMB_colour1.Visible = false;
                wrnctl.CMB_colour2.Visible = false;
            }

            panel1.Controls.Add(wrnctl);

            y = wrnctl.Bottom;

            if (item.Child != null)
            {
                wrnctl = addwarningcontrol(x += 5, y, item.Child, true);
            }

            return wrnctl;
        }