Merge commit 'refs/pull/63142/head' of github.com:Microsoft/vscode into pr/63142

This commit is contained in:
Joao Moreno 2018-11-16 09:17:28 +01:00
commit 98bcd06d2f
2 changed files with 5 additions and 3 deletions

View file

@ -849,7 +849,8 @@ export class TreeView extends HeightMap {
}
private set scrollHeight(scrollHeight: number) {
this.scrollableElement.setScrollDimensions({ scrollHeight });
const horizontalScrollHeight = this.horizontalScrolling ? 10 : 0;
this.scrollableElement.setScrollDimensions({ scrollHeight: scrollHeight + horizontalScrollHeight });
}
public get viewWidth(): number {
@ -871,8 +872,9 @@ export class TreeView extends HeightMap {
}
public set scrollTop(scrollTop: number) {
const horizontalScrollHeight = this.horizontalScrolling ? 10 : 0;
this.scrollableElement.setScrollDimensions({
scrollHeight: this.getContentHeight()
scrollHeight: this.getContentHeight() + horizontalScrollHeight
});
this.scrollableElement.setScrollPosition({
scrollTop: scrollTop

View file

@ -261,7 +261,7 @@ export class DebugHoverWidget implements IContentWidget {
if (visibleElementsCount === 0) {
this.doShow(this.showAtPosition, this.tree.getInput(), false, true);
} else {
const height = Math.min(visibleElementsCount, MAX_ELEMENTS_SHOWN) * 18;
const height = Math.min(visibleElementsCount, MAX_ELEMENTS_SHOWN) * 18 + 10; // add 10 px for the horizontal scroll bar
if (this.treeContainer.clientHeight !== height) {
this.treeContainer.style.height = `${height}px`;