Beispiel #1
0
        private static Int32 EnsureValue(GroupCountUpDown item)
        {
            var value = item.Value;

            if (!value.HasValue)
            {
                throw new NotSupportedException();                  // <Null> values not allowed.
            }
            return(value.Value);
        }
Beispiel #2
0
        public void AddChild(GroupCountUpDown item)
        {
            if (Object.ReferenceEquals(item, null))
            {
                throw new ArgumentNullException(nameof(item));
            }

            item.IsCoupled = false;
            this.children.Add(item);
            this.InvalidateConstraint();
        }
Beispiel #3
0
        public Boolean RemoveChild(GroupCountUpDown item)
        {
            if (Object.ReferenceEquals(item, null))
            {
                throw new ArgumentNullException(nameof(item));
            }

            if (!this.children.Remove(item))
            {
                return(false);
            }
            this.InvalidateConstraint();
            return(true);
        }