Skip to content

Commit 6ec77a5

Browse files
Fix scrollbar visibility when horizontal
1 parent dc1f03a commit 6ec77a5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/scrollbar.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -243,7 +243,7 @@ Blockly.Scrollbar.prototype.resize = function(opt_metrics) {
243243
// Only show the scrollbar if needed.
244244
// Ideally this would also apply to scrollbar pairs, but that's a bigger
245245
// headache (due to interactions with the corner square).
246-
this.setVisible(outerLength < hostMetrics.contentHeight);
246+
this.setVisible(outerLength < hostMetrics.contentWidth);
247247
}
248248
this.ratio_ = outerLength / hostMetrics.contentWidth;
249249
if (this.ratio_ === -Infinity || this.ratio_ === Infinity ||

0 commit comments

Comments
 (0)