14 lines
334 B
TypeScript
14 lines
334 B
TypeScript
// Copyright 2021 Signal Messenger, LLC
|
|
// SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
import type { BrowserWindow } from 'electron';
|
|
|
|
export function toggleMaximizedBrowserWindow(
|
|
browserWindow: BrowserWindow
|
|
): void {
|
|
if (browserWindow.isMaximized()) {
|
|
browserWindow.unmaximize();
|
|
} else {
|
|
browserWindow.maximize();
|
|
}
|
|
}
|