Example #1
0
        public ISelectionGroup <T> GetSelectionGroup(string groupName)
        {
            ISelectionGroup <T> group;

            if (!groups.TryGetValue(groupName, out group))
            {
                group = new SelectionGroup <T>();
                groups.Add(groupName, group);
            }

            return(group);
        }
Example #2
0
        private ISelectionGroup <RadioButton> GetDefaultGroup()
        {
            if (LogicalParent == null)
            {
                return(null);
            }

            ISelectionGroup <RadioButton> group = (ISelectionGroup <RadioButton>)LogicalParent.GetValue(SelectionGroupProperty);

            if (group == null)
            {
                group = new SelectionGroup <RadioButton>();
                LogicalParent.SetValue(SelectionGroupProperty, group);
            }

            return(group);
        }