perf: v3.26.180 停用常驻合成层(窗口可见时持续 CPU)
Verify (Gitea) / gate (build · unit · facts) (push) Failing after 9m19s
Verify (Gitea) / gate (build · unit · facts) (push) Failing after 9m19s
This commit is contained in:
1 parent
7ca372efec
commit
190ec3934b
5 files changed
+8
-6
No files matched your search
+1
-1
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "image-workbench-web",
|
||||
"private": true,
|
||||
"version": "3.26.179",
|
||||
"version": "3.26.180",
|
||||
"description": "Browser-based node canvas image workbench",
|
||||
"scripts": {
|
||||
"build": "node scripts/build.js && node scripts/copy-plugins.js",
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "image-workbench"
|
||||
version = "3.26.179"
|
||||
version = "3.26.180"
|
||||
description = "无限画布 · 生图工作台桌面版"
|
||||
authors = ["malongan"]
|
||||
license = ""
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"$schema": "../node_modules/@tauri-apps/cli/config.schema.json",
|
||||
"productName": "image-workbench",
|
||||
"version": "3.26.179",
|
||||
"version": "3.26.180",
|
||||
"identifier": "com.malongan.imageworkbench",
|
||||
"build": {
|
||||
"frontendDist": "../dist",
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
// v3.26.117:内存回收。只清可重建的缓存(撤销历史/缩略图/图片字节缓存)并把非活动画板降回引用形态,不删用户数据。
|
||||
el('button', { className: 'iwb-btn iwb-btn-sm', title: '立即回收内存:清撤销历史、缩略图缓存与图片字节缓存,非活动画板降回引用形态(不删任何画板/图片)', onClick: async () => { if (typeof reclaimMemory === 'function') await reclaimMemory() } }, '立即回收内存'),
|
||||
el('button', { className: 'iwb-btn iwb-btn-sm', title: '导出完整诊断 JSON(下载文件)', onClick: () => { if (typeof props.onExportDiag === 'function') props.onExportDiag(); else setMsg({ type: 'err', text: '当前环境不支持诊断导出' }) } }, '导出 JSON'),
|
||||
el('label', { className: 'iwb-diag-kv', title: '打开后整个画布世界会被提升成一个常驻合成层:拖拽/缩放更顺,但内存会明显上涨(实测 +700MB 级)。改完等 10 秒看「进程实测」对比。' },
|
||||
el('label', { className: 'iwb-diag-kv', title: '已弃用:常驻合成层会让窗口可见时持续占用 CPU(实测 15%,最小化即消失),手势期间已有临时提升,无需常驻。' },
|
||||
el('input', { type: 'checkbox', checked: !!(extras && extras.layers), onChange: (e) => { if (typeof props.onToggleLayers === 'function') props.onToggleLayers(e.target.checked) } }),
|
||||
' 合成层常驻提升'),
|
||||
el('label', { className: 'iwb-diag-kv', title: '记录 rAF 帧时长与 JS 长任务到 _boot.log(每 60s 一条),用于判断卡顿/高 CPU 是渲染还是脚本' },
|
||||
|
||||
@@ -1222,11 +1222,13 @@ body .iwb-history-embedded .iwb-history-item.iwb-history-selected:hover img {
|
||||
.iwb-canvas.iwb-gesture .iwb-statusbar,
|
||||
.iwb-canvas.iwb-gesture .iwb-statusbar *:not(img) { -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
|
||||
.iwb-world { will-change: auto; }
|
||||
:root[data-layers="on"] .iwb-world { will-change: transform; }
|
||||
/* v3.26.180:常驻合成层已停用 —— 它会强制把整个世界层保持为一张大合成层,
|
||||
实测“窗口可见时 CPU 持续 15%、最小化就掉”,且 155 起手势期间已有临时提升,常驻没有收益。 */
|
||||
:root[data-layers="on"] .iwb-world { will-change: auto; }
|
||||
/* v3.26.137:毛玻璃开关(诊断页)。关掉后所有 backdrop-filter 失效,用于二分 graphics 占用 */
|
||||
:root[data-noblur="on"] *, :root[data-noblur="on"] *::before, :root[data-noblur="on"] *::after { backdrop-filter: none !important; -webkit-backdrop-filter: none !important; }
|
||||
.iwb-grid { will-change: auto; }
|
||||
:root[data-layers="on"] .iwb-grid { will-change: transform; }
|
||||
:root[data-layers="on"] .iwb-grid { will-change: auto; }
|
||||
/* v15:左侧资源面板展开时浮在画布上层,不移动画布位置 */
|
||||
.iwb-overlay.drawer-open .iwb-canvas { left: 0 !important; }
|
||||
/* 停靠栏时代:工具栏/小地图按 --iwb-dock-* 让位(画布仍不动) */
|
||||
|
||||
Reference in new issue
Block a user