Storage for button content value information.
Inheritance: Storage
Exemplo n.º 1
0
 /// <summary>
 /// Value copy form the provided source to ourself.
 /// </summary>
 /// <param name="source">Source instance.</param>
 public virtual void CopyFrom(ButtonImageStates source)
 {
     ImageDisabled = source.ImageDisabled;
     ImageNormal   = source.ImageNormal;
     ImagePressed  = source.ImagePressed;
     ImageTracking = source.ImageTracking;
 }
Exemplo n.º 2
0
        /// <summary>
        /// Initialize a new instance of the ButtonValues class.
        /// </summary>
        /// <param name="needPaint">Delegate for notifying paint requests.</param>
        public ButtonValues(NeedPaintHandler needPaint)
        {
            // Store the provided paint notification delegate
            NeedPaint = needPaint;

            // Set initial values
            _image                 = null;
            _transparent           = Color.Empty;
            _text                  = _defaultText;
            _extraText             = _defaultExtraText;
            _imageStates           = CreateImageStates();
            _imageStates.NeedPaint = needPaint;
        }
Exemplo n.º 3
0
        /// <summary>
        /// Initialize a new instance of the ButtonValues class.
        /// </summary>
        /// <param name="needPaint">Delegate for notifying paint requests.</param>
        public ButtonValues(NeedPaintHandler needPaint)
        {
            // Store the provided paint notification delegate
            NeedPaint = needPaint;

            // Set initial values
            _image = null;
            _transparent = Color.Empty;
            _text = _defaultText;
            _extraText = _defaultExtraText;
            _imageStates = CreateImageStates();
            _imageStates.NeedPaint = needPaint;
        }
Exemplo n.º 4
0
        /// <summary>
        /// Initialize a new instance of the ColorButtonValues class.
        /// </summary>
        /// <param name="needPaint">Delegate for notifying paint requests.</param>
        public ColorButtonValues(NeedPaintHandler needPaint)
        {
            // Store the provided paint notification delegate
            NeedPaint = needPaint;

            // Set initial values
            _image                 = _defaultImage;
            _transparent           = Color.Empty;
            _text                  = _defaultText;
            _extraText             = _defaultExtraText;
            _imageStates           = CreateImageStates();
            _imageStates.NeedPaint = needPaint;
            _emptyBorderColor      = Color.Gray;
            _selectedColor         = Color.Red;
            _selectedRect          = new Rectangle(0, 12, 16, 4);
        }
Exemplo n.º 5
0
        /// <summary>
        /// Initialize a new instance of the ColorButtonValues class.
        /// </summary>
        /// <param name="needPaint">Delegate for notifying paint requests.</param>
        public ColorButtonValues(NeedPaintHandler needPaint)
        {
            // Store the provided paint notification delegate
            NeedPaint = needPaint;

            // Set initial values
            _image = _defaultImage;
            _transparent = Color.Empty;
            _text = _defaultText;
            _extraText = _defaultExtraText;
            _imageStates = CreateImageStates();
            _imageStates.NeedPaint = needPaint;
            _emptyBorderColor = Color.Gray;
            _selectedColor = Color.Red;
            _selectedRect = new Rectangle(0, 12, 16, 4);
        }
Exemplo n.º 6
0
 /// <summary>
 /// Value copy form the provided source to ourself.
 /// </summary>
 /// <param name="source">Source instance.</param>
 public virtual void CopyFrom(ButtonImageStates source)
 {
     ImageDisabled = source.ImageDisabled;
     ImageNormal = source.ImageNormal;
     ImagePressed = source.ImagePressed;
     ImageTracking = source.ImageTracking;
 }