From f3d0da20753500c9685bfaa2dc5b39a71a635f37 Mon Sep 17 00:00:00 2001 From: Bryan Ashby Date: Sat, 6 Aug 2022 00:43:26 -0600 Subject: [PATCH] Fix dumb bug with 'focusItemAtTop' --- core/vertical_menu_view.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/vertical_menu_view.js b/core/vertical_menu_view.js index aa196f80..be5ce132 100644 --- a/core/vertical_menu_view.js +++ b/core/vertical_menu_view.js @@ -50,7 +50,7 @@ function VerticalMenuView(options) { this.updateViewVisibleItems = function () { self.maxVisibleItems = Math.ceil(self.dimens.height / (self.itemSpacing + 1)); - const topIndex = (this.focusItemAtTop ? throws.focusedItemIndex : 0) || 0; + const topIndex = (this.focusItemAtTop ? this.focusedItemIndex : 0) || 0; self.viewWindow = { top: topIndex, @@ -195,7 +195,7 @@ VerticalMenuView.prototype.setFocusItemIndex = function (index) { ? this.items.length - index : this.items.length; if (remainAfterFocus >= this.maxVisibleItems) { - const topIndex = (this.focusItemAtTop ? throws.focusedItemIndex : 0) || 0; + const topIndex = (this.focusItemAtTop ? this.focusedItemIndex : 0) || 0; this.viewWindow = { top: topIndex,