Skip to content

Commit 052c9d5

Browse files
committed
fix(grid): check column list in setters #4726
1 parent 94d392f commit 052c9d5

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

projects/igniteui-angular/src/lib/grids/grid-base.component.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -521,12 +521,11 @@ export abstract class IgxGridBaseComponent extends DisplayDensityBase implements
521521
*/
522522
set rowSelectable(val: boolean) {
523523
this._rowSelection = val;
524-
if (this.gridAPI.grid) {
524+
if (this.gridAPI.grid && this.columnList) {
525525

526526
// should selection persist?
527527
this.allRowsSelected = false;
528528
this.deselectAllRows();
529-
this.resetCachedWidths();
530529
this.calculateGridSizes();
531530
}
532531
}
@@ -545,8 +544,7 @@ export abstract class IgxGridBaseComponent extends DisplayDensityBase implements
545544
*/
546545
set rowDraggable(val: boolean) {
547546
this._rowDrag = val;
548-
if (this.gridAPI.grid) {
549-
this.resetCachedWidths();
547+
if (this.gridAPI.grid && this.columnList) {
550548
this.calculateGridSizes();
551549
}
552550
}

0 commit comments

Comments
 (0)