From 604d7c464f487fea7e553379d84f2bf0327a3eb1 Mon Sep 17 00:00:00 2001 From: Eugene Pankov Date: Sat, 13 Mar 2021 21:43:36 +0100 Subject: [PATCH] fixed cycling tab reordering via hotkeys - fixes #3510 --- terminus-core/src/services/app.service.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/terminus-core/src/services/app.service.ts b/terminus-core/src/services/app.service.ts index d9b85bfa..c0beed64 100644 --- a/terminus-core/src/services/app.service.ts +++ b/terminus-core/src/services/app.service.ts @@ -263,7 +263,7 @@ export class AppService { if (tabIndex > 0) { this.swapTabs(this._activeTab, this.tabs[tabIndex - 1]) } else if (this.config.store.appearance.cycleTabs) { - this.swapTabs(this._activeTab, this.tabs[this.tabs.length - 1]) + this.tabs.push(this.tabs.shift()!) } } } @@ -277,7 +277,7 @@ export class AppService { if (tabIndex < this.tabs.length - 1) { this.swapTabs(this._activeTab, this.tabs[tabIndex + 1]) } else if (this.config.store.appearance.cycleTabs) { - this.swapTabs(this._activeTab, this.tabs[0]) + this.tabs.unshift(this.tabs.pop()!) } } }