From ce92dfa048df1ccb27bbfabbf8a13f6ffb50df62 Mon Sep 17 00:00:00 2001 From: Wlowscha <54003515+Wlowscha@users.noreply.github.com> Date: Wed, 19 Feb 2025 20:54:45 +0100 Subject: [PATCH] Filter changes to starter select screen --- src/ui/starter-select-ui-handler.ts | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-) diff --git a/src/ui/starter-select-ui-handler.ts b/src/ui/starter-select-ui-handler.ts index 65c159c62a8..f6ecf150f9f 100644 --- a/src/ui/starter-select-ui-handler.ts +++ b/src/ui/starter-select-ui-handler.ts @@ -1301,16 +1301,11 @@ export default class StarterSelectUiHandler extends MessageUiHandler { if (this.filterMode && this.filterBar.openDropDown) { // CANCEL with a filter menu open > close it this.filterBar.toggleDropDown(this.filterBarCursor); - - // if there are possible starters go the first one of the list - if (numberOfStarters > 0) { - this.setFilterMode(false); - this.scrollCursor = 0; - this.updateScroll(); - this.setCursor(0); - } success = true; - + } else if (this.filterMode && !this.filterBar.getFilter(this.filterBarCursor).hasDefaultValues()) { + this.filterBar.resetSelection(this.filterBarCursor); + this.updateStarters; + success = true; } else if (this.statsMode) { this.toggleStatsMode(false); success = true;