AdvancedDataGridView.TreeGridView.OnRowEnter C# (CSharp) Method

OnRowEnter() protected method

protected OnRowEnter ( System.Windows.Forms.DataGridViewCellEventArgs e ) : void
e System.Windows.Forms.DataGridViewCellEventArgs
return void
        protected override void OnRowEnter(DataGridViewCellEventArgs e)
        {
            // ensure full row select
            base.OnRowEnter(e);
            if (this.SelectionMode == DataGridViewSelectionMode.CellSelect ||
                (this.SelectionMode == DataGridViewSelectionMode.FullRowSelect &&
                base.Rows[e.RowIndex].Selected == false))
            {
                this.SelectionMode = DataGridViewSelectionMode.FullRowSelect;
                base.Rows[e.RowIndex].Selected = true;
            }
        }