@@ -411,7 +411,7 @@ export class SettingsEditor2 extends EditorPane {
411
411
return ;
412
412
}
413
413
414
- this . layoutTrees ( dimension ) ;
414
+ this . layoutSplitView ( dimension ) ;
415
415
416
416
const innerWidth = Math . min ( 1000 , dimension . width ) - 24 * 2 ; // 24px padding on left and right;
417
417
// minus padding inside inputbox, countElement width, controls width, extra padding before countElement
@@ -714,6 +714,7 @@ export class SettingsEditor2 extends EditorPane {
714
714
maximumSize : Number . POSITIVE_INFINITY ,
715
715
layout : ( width ) => {
716
716
this . tocTreeContainer . style . width = `${ width } px` ;
717
+ this . tocTree . layout ( undefined , width ) ;
717
718
}
718
719
} , startingWidth , undefined , true ) ;
719
720
this . splitView . addView ( {
@@ -723,6 +724,7 @@ export class SettingsEditor2 extends EditorPane {
723
724
maximumSize : Number . POSITIVE_INFINITY ,
724
725
layout : ( width ) => {
725
726
this . settingsTreeContainer . style . width = `${ width } px` ;
727
+ this . settingsTree . layout ( undefined , width ) ;
726
728
}
727
729
} , Sizing . Distribute , undefined , true ) ;
728
730
this . _register ( this . splitView . onDidSashReset ( ( ) => {
@@ -1534,17 +1536,10 @@ export class SettingsEditor2 extends EditorPane {
1534
1536
} ) ;
1535
1537
}
1536
1538
1537
- private layoutTrees ( dimension : DOM . Dimension ) : void {
1539
+ private layoutSplitView ( dimension : DOM . Dimension ) : void {
1538
1540
const listHeight = dimension . height - ( 72 + 11 + 14 /* header height + editor padding */ ) ;
1539
- const settingsTreeHeight = listHeight ;
1540
- this . settingsTreeContainer . style . height = `${ settingsTreeHeight } px` ;
1541
- this . settingsTree . layout ( settingsTreeHeight , dimension . width ) ;
1542
1541
1543
- const tocTreeHeight = settingsTreeHeight ;
1544
- this . tocTreeContainer . style . height = `${ tocTreeHeight } px` ;
1545
- this . tocTree . layout ( tocTreeHeight ) ;
1546
-
1547
- this . splitView . el . style . height = `${ settingsTreeHeight } px` ;
1542
+ this . splitView . el . style . height = `${ listHeight } px` ;
1548
1543
1549
1544
// We call layout first so the splitView has an idea of how much
1550
1545
// space it has, otherwise setViewVisible results in the first panel
0 commit comments