Skip to content

Commit 282ac0e

Browse files
authored
Merge pull request #102479 from microsoft/joao/release/1.47/fix-102358
Release fixes #102358
2 parents 70ced3a + f38cc4e commit 282ac0e

File tree

1 file changed

+4
-9
lines changed

1 file changed

+4
-9
lines changed

src/vs/workbench/contrib/scm/browser/scmViewPane.ts

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -316,19 +316,14 @@ class InputRenderer implements ICompressibleTreeRenderer<ISCMInput, FuzzyScore,
316316
}
317317
};
318318

319-
const initialRender = () => {
319+
const startListeningContentHeightChange = () => {
320320
disposables.add(templateData.inputWidget.onDidChangeContentHeight(onDidChangeContentHeight));
321321
onDidChangeContentHeight();
322322
};
323323

324-
const contentHeight = templateData.inputWidget.getContentHeight();
325-
326-
if (contentHeight !== InputRenderer.DEFAULT_HEIGHT) {
327-
const timeout = setTimeout(initialRender, 0);
328-
disposables.add({ dispose: () => clearTimeout(timeout) });
329-
} else {
330-
initialRender();
331-
}
324+
// Setup height change listener on next tick
325+
const timeout = setTimeout(startListeningContentHeightChange, 0);
326+
disposables.add({ dispose: () => clearTimeout(timeout) });
332327

333328
// Layout the editor whenever the outer layout happens
334329
const layoutEditor = () => templateData.inputWidget.layout();

0 commit comments

Comments
 (0)