Пример #1
0
        /// <summary>
        /// Initialise default values
        /// </summary>
        private void Init()
        {
            this.text = null;
            this.data = null;
            this.rendererData = null;
            this.tag = null;
            this.row = null;
            this.index = -1;
            this.cellStyle = null;
            this.tooltipText = null;

            this.state = (byte) (STATE_EDITABLE | STATE_ENABLED);
        }
Пример #2
0
        /// <summary>
        /// Releases all resources used by the Cell
        /// </summary>
        public void Dispose()
        {
            if (!this.disposed)
            {
                this.text = null;
                this.data = null;
                this.tag = null;
                this.rendererData = null;

                if (this.row != null)
                {
                    this.row.Cells.Remove(this);
                }

                this.row = null;
                this.index = -1;
                this.cellStyle = null;
                this.tooltipText = null;

                this.state = (byte) 0;

                this.disposed = true;
            }
        }
Пример #3
0
        /// <summary>
        /// Initializes a new instance of the Cell class with the specified text 
        /// and CellStyle
        /// </summary>
        /// <param name="value">The object displayed in the Cell</param>
        /// <param name="cellStyle">A CellStyle that specifies the visual appearance 
        /// of the Cell</param>
        public Cell(object value, CellStyle cellStyle)
        {
            this.Init();

            this.data = value;
            this.cellStyle = cellStyle;
        }
Пример #4
0
        /// <summary>
        /// Initializes a new instance of the Cell class with the specified text, 
        /// object and CellStyle
        /// </summary>
        /// <param name="text">The text displayed in the Cell</param>
        /// <param name="value">The object displayed in the Cell</param>
        /// <param name="cellStyle">A CellStyle that specifies the visual appearance 
        /// of the Cell</param>
        public Cell(string text, object value, CellStyle cellStyle)
        {
            this.Init();

            this.text = text;
            this.data = value;
            this.cellStyle = cellStyle;
        }
Пример #5
0
        /// <summary>
        /// Initializes a new instance of the Cell class with the specified text 
        /// and CellStyle
        /// </summary>
        /// <param name="text">The text displayed in the Cell</param>
        /// <param name="cellStyle">A CellStyle that specifies the visual appearance 
        /// of the Cell</param>
        public Cell(string text, CellStyle cellStyle)
        {
            this.Init();

            this.text = text;
            this.cellStyle = cellStyle;
        }