Ejemplo n.º 1
0
        private static List<Form> GetAllPeerForms(Form form)
        {
            if (form == null)
            {
                return new List<Form>();
            }

            if (form.Owner != null)
            {
                return GetAllPeerForms(form.Owner);
            }

            List<Form> forms = new List<Form>();
            forms.Add(form);
            forms.AddRange(form.OwnedForms);

            return forms;
        }