From 6d0b2608a27e856827045403bbb47ea791a9ef08 Mon Sep 17 00:00:00 2001 From: Eugene Pankov Date: Mon, 27 Jul 2020 15:56:09 +0200 Subject: [PATCH] added an option to disable the global hotkey to the welcome tab (fixes #1509, fixes #2809) --- .../src/components/welcomeTab.component.pug | 13 ++++++++++--- .../src/components/welcomeTab.component.ts | 4 ++++ 2 files changed, 14 insertions(+), 3 deletions(-) diff --git a/terminus-core/src/components/welcomeTab.component.pug b/terminus-core/src/components/welcomeTab.component.pug index 5195dd0d..ad91f9d8 100644 --- a/terminus-core/src/components/welcomeTab.component.pug +++ b/terminus-core/src/components/welcomeTab.component.pug @@ -9,18 +9,25 @@ .form-line .header .title Enable analytics - .description Help us track the number of Terminus installs across the world! + .description Help track the number of Terminus installs across the world! toggle([(ngModel)]='config.store.enableAnalytics') + .form-line .header - .title Enable SSH plugin + .title Enable global hotkey (#[strong Ctrl-Space]) + .description Toggles the Terminus window visibility + toggle([(ngModel)]='enableGlobalHotkey') + + .form-line + .header + .title Enable #[strong SSH] plugin .description Adds an SSH connection manager UI to Terminus toggle([(ngModel)]='enableSSH') .form-line .header - .title Enable Serial plugin + .title Enable #[strong Serial] plugin .description Allows attaching Terminus to serial ports toggle([(ngModel)]='enableSerial') diff --git a/terminus-core/src/components/welcomeTab.component.ts b/terminus-core/src/components/welcomeTab.component.ts index b6a65753..c125ec6e 100644 --- a/terminus-core/src/components/welcomeTab.component.ts +++ b/terminus-core/src/components/welcomeTab.component.ts @@ -13,6 +13,7 @@ import { HostAppService } from '../services/hostApp.service' export class WelcomeTabComponent extends BaseTabComponent { enableSSH = false enableSerial = false + enableGlobalHotkey = true constructor ( private hostApp: HostAppService, @@ -33,6 +34,9 @@ export class WelcomeTabComponent extends BaseTabComponent { if (!this.enableSerial) { this.config.store.pluginBlacklist.push('serial') } + if (!this.enableGlobalHotkey) { + this.config.store.hotkeys['toggle-window'] = [] + } this.config.save() this.hostApp.getWindow().reload() }