diff --git a/app/lib/app.ts b/app/lib/app.ts index 2da94afc..6a6eb05f 100644 --- a/app/lib/app.ts +++ b/app/lib/app.ts @@ -12,7 +12,7 @@ export class Application { ipcMain.on('app:config-change', (_event, config) => { this.broadcast('host:config-change', config) }) - + ipcMain.on('app:register-global-hotkey', (_event, specs) => { globalShortcut.unregisterAll() for (let spec of specs) { @@ -64,7 +64,7 @@ export class Application { return window } - onGlobalHotkey () { + onGlobalHotkey (): void { if (this.windows.some(x => x.isFocused())) { for (let window of this.windows) { window.hide() @@ -76,7 +76,7 @@ export class Application { } } - presentAllWindows() { + presentAllWindows (): void { for (let window of this.windows) { window.present() } diff --git a/app/lib/window.ts b/app/lib/window.ts index ce815710..46234440 100644 --- a/app/lib/window.ts +++ b/app/lib/window.ts @@ -169,7 +169,7 @@ export class Window { return this.window.isFocused() } - hide () { + hide (): void { if (process.platform === 'darwin') { // Lose focus Menu.sendActionToFirstResponder('hide:') @@ -180,7 +180,7 @@ export class Window { } } - present () { + present (): void { if (!this.window.isVisible()) { // unfocused, invisible this.window.show() diff --git a/terminus-core/src/services/hostApp.service.ts b/terminus-core/src/services/hostApp.service.ts index 4eed64aa..081a9db1 100644 --- a/terminus-core/src/services/hostApp.service.ts +++ b/terminus-core/src/services/hostApp.service.ts @@ -250,7 +250,7 @@ export class HostAppService { /** * Notifies other windows of config file changes */ - broadcastConfigChange (configStore: any): void { + broadcastConfigChange (configStore: {[k: string]: any}): void { this.electron.ipcRenderer.send('app:config-change', configStore) } diff --git a/terminus-core/src/services/hotkeys.service.ts b/terminus-core/src/services/hotkeys.service.ts index c0b5f43b..cd2d5c89 100644 --- a/terminus-core/src/services/hotkeys.service.ts +++ b/terminus-core/src/services/hotkeys.service.ts @@ -197,7 +197,7 @@ export class HotkeysService { console.error('Could not register the global hotkey:', err) } }) - + this.hostApp.registerGlobalHotkey(specs) } diff --git a/terminus-terminal/src/shells/wsl.ts b/terminus-terminal/src/shells/wsl.ts index 7d9c1bf7..86763f9e 100644 --- a/terminus-terminal/src/shells/wsl.ts +++ b/terminus-terminal/src/shells/wsl.ts @@ -88,9 +88,9 @@ export class WSLShellProvider extends ShellProvider { if (!childKey.DistributionName) { continue } - const wslVersion = (childKey.Flags.value & 8) ? 2 : 1 + const wslVersion = childKey.Flags.value & 8 ? 2 : 1 const name = childKey.DistributionName.value - const fsBase = (wslVersion === 2) ? `\\\\wsl$\\${name}` : (childKey.BasePath.value as string + '\\rootfs') + const fsBase = wslVersion === 2 ? `\\\\wsl$\\${name}` : childKey.BasePath.value as string + '\\rootfs' const shell: Shell = { id: `wsl-${slugify(name)}`, name: `WSL / ${name}`,