fix(app): make click-through the default and move animation pausing to Accessibility (#1722)

This commit is contained in:
Hampus authored and GitHub committed 2026-08-18 19:40:35 +02:00
1 parent 9e89539f0a
commit 4bbfee4cec
19 files changed
+96 -248

No files matched your search

@@ -322,7 +322,6 @@ function formatWindowBehavior(settings: DesktopWindowBehaviorSettings): string {
`activeSmoothScrolling=${settings.activeSmoothScrolling}`,
`middleClickAutoscroll=${settings.middleClickAutoscroll}`,
`activeMiddleClickAutoscroll=${settings.activeMiddleClickAutoscroll}`,
`firstClickPassThroughWhenUnfocused=${settings.firstClickPassThroughWhenUnfocused}`,
].join(', ');
}
-5
View File
@@ -62,7 +62,6 @@ import {
import {
clearSavedWindowBounds,
closeThemeStudioPopoutWindow,
desktopFirstClickPassThroughPendingRestart,
desktopTransparencyPendingRestart,
desktopUseNativeTitleBarPendingRestart,
focusThemeStudioPopoutWindow,
@@ -123,9 +122,6 @@ function normalizeDesktopWindowBehaviorUpdate(value: unknown): Partial<DesktopWi
if (typeof value.middleClickAutoscroll === 'boolean') {
update.middleClickAutoscroll = value.middleClickAutoscroll;
}
if (typeof value.firstClickPassThroughWhenUnfocused === 'boolean') {
update.firstClickPassThroughWhenUnfocused = value.firstClickPassThroughWhenUnfocused;
}
return update;
}
@@ -255,7 +251,6 @@ export function registerIpcHandlers(): void {
ipcMain.handle('desktop-window-behavior-pending-restart', (): boolean => {
return (
desktopTrayChangePendingRestart() ||
desktopFirstClickPassThroughPendingRestart() ||
desktopUseNativeTitleBarPendingRestart() ||
desktopTransparencyPendingRestart()
);
+1 -9
View File
@@ -145,7 +145,6 @@ interface CreateWindowOptions {
let mainWindow: BrowserWindow | null = null;
let windowStateFile: string;
let isQuitting = false;
let initialAcceptFirstMouseOnFocus: boolean | null = null;
let initialUseNativeTitleBar: boolean | null = null;
let initialAllowTransparency: boolean | null = null;
let themeStudioPopoutWindow: BrowserWindow | null = null;
@@ -331,12 +330,6 @@ export function getMainWindow(): BrowserWindow | null {
return mainWindow;
}
export function desktopFirstClickPassThroughPendingRestart(): boolean {
if (process.platform !== 'darwin') return false;
if (initialAcceptFirstMouseOnFocus === null) return false;
return getDesktopWindowBehaviorSettings().firstClickPassThroughWhenUnfocused !== initialAcceptFirstMouseOnFocus;
}
export function getActiveUseNativeTitleBar(): boolean {
return initialUseNativeTitleBar ?? false;
}
@@ -730,8 +723,7 @@ export function createWindow(options: CreateWindowOptions = {}): BrowserWindow {
const desktopWindowBehavior = getDesktopWindowBehaviorSettings();
const allowTransparency = desktopWindowBehavior.allowTransparency;
const useNativeTitleBar = getEffectiveUseNativeTitleBar(desktopWindowBehavior);
const acceptFirstMouseOnFocus = isMac && desktopWindowBehavior.firstClickPassThroughWhenUnfocused;
initialAcceptFirstMouseOnFocus = acceptFirstMouseOnFocus;
const acceptFirstMouseOnFocus = isMac;
initialUseNativeTitleBar = useNativeTitleBar;
initialAllowTransparency = allowTransparency;
const appUrl = getAppUrl();