From 3f5533c09942806e49e446157d644976af5718a4 Mon Sep 17 00:00:00 2001 From: Chris233 Date: Sun, 2 Aug 2026 18:52:01 +0800 Subject: [PATCH] =?UTF-8?q?fix(windows):=20=E4=B8=BB=E7=AA=97=E5=8F=A3?= =?UTF-8?q?=E6=94=B9=E4=B8=BA=E4=B8=8D=E9=80=8F=E6=98=8E=E2=80=94=E2=80=94?= =?UTF-8?q?=E6=B6=88=E9=99=A4=E5=BD=95=E9=9F=B3=E6=97=B6=20DWM/GPU=20?= =?UTF-8?q?=E9=A5=B1=E5=92=8C=E5=AF=BC=E8=87=B4=E7=9A=84=E7=B3=BB=E7=BB=9F?= =?UTF-8?q?=E5=8D=A1=E9=A1=BF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 主窗口 transparent:true 使 WebView2 内容整页走 per-pixel alpha 分层合成, 但 UI 所有大面积层(winchrome/shell/sidebar/内容区)都是不透明背景, Mica 磨砂实际被完全盖住,透明是纯 GPU 成本零视觉收益。 录音期间叠加胶囊 60fps WebGL + 30Hz 事件,DWM 被拖到饱和时: - 其他软件合成帧送不出去 → 全局无响应 - 任务栏右键触发缩略图/重合成 → GPU 飙升 新增 tauri.windows.conf.json 平台覆盖(json_patch 数组整体替换, 必须完整列出窗口),main 窗口 transparent:false,capsule 保留透明。 macOS/Linux 不受影响。参考 tauri.linux.conf.json 既有先例。 --- .../app/src-tauri/tauri.windows.conf.json | 44 +++++++++++++++++++ 1 file changed, 44 insertions(+) create mode 100644 openless-all/app/src-tauri/tauri.windows.conf.json diff --git a/openless-all/app/src-tauri/tauri.windows.conf.json b/openless-all/app/src-tauri/tauri.windows.conf.json new file mode 100644 index 00000000..5c87f3f0 --- /dev/null +++ b/openless-all/app/src-tauri/tauri.windows.conf.json @@ -0,0 +1,44 @@ +{ + "$schema": "https://schema.tauri.app/config/2", + "app": { + "windows": [ + { + "label": "main", + "title": "OpenLess", + "width": 1240, + "height": 800, + "minWidth": 980, + "minHeight": 640, + "resizable": true, + "decorations": true, + "transparent": false, + "shadow": true, + "hiddenTitle": true, + "titleBarStyle": "Overlay", + "trafficLightPosition": { + "x": 14, + "y": 20 + }, + "visible": false, + "acceptFirstMouse": true + }, + { + "label": "capsule", + "url": "index.html?window=capsule", + "title": "OpenLess Capsule", + "width": 460, + "height": 180, + "decorations": false, + "transparent": true, + "shadow": false, + "alwaysOnTop": true, + "skipTaskbar": true, + "resizable": false, + "focus": false, + "visible": false, + "center": false, + "acceptFirstMouse": true + } + ] + } +}