Skip to content

Commit d5af2a2

Browse files
committed
fixes issue where hidden element orientation is not updated when hidden
1 parent 5df1ca3 commit d5af2a2

1 file changed

Lines changed: 10 additions & 4 deletions

File tree

src/vs/base/browser/ui/grid/grid.ts

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -698,13 +698,19 @@ export class View implements IView {
698698
}
699699

700700
layout(width: number, height: number, orientation: Orientation): void {
701-
if (!this.visible) {
701+
if (!this.visible && this.orientation === orientation) {
702702
return;
703703
}
704704

705-
this.view.layout(width, height, orientation);
706-
this.width = width;
707-
this.height = height;
705+
706+
707+
if (this.visible) {
708+
this.view.layout(width, height, orientation);
709+
710+
this.width = width;
711+
this.height = height;
712+
}
713+
708714
this.orientation = orientation;
709715
}
710716
}

0 commit comments

Comments
 (0)