Files
image-workbench-desktop/src-tauri/Cargo.toml
T
qiqi dce8aac1f3 refactor!: 下线画布内网页节点(原生子 webview 路线的维护成本远超收益)
背景:画布内网页用 Window::add_child 挂原生子 webview,连续踩到三个平台坑且修不干净:
- hide() 之后 show() 静默失效(都返回 Ok,网页永久不再绘制);
- get_webview_window("main") 在出现任何子 webview 后永久返回 None;
- 子 webview 抢指针事件,拖动只能靠标题栏。
剩下的日常操作(换工作区、LOD 降级、快速拖拽、被遮挡)全靠每帧推 bounds / 挪出窗口 /
延迟 900ms 回收这类脆弱补偿兜底 ⇒ 撤掉,不留半成品。独立窗口浏览器不受影响。

删除:
- Rust:canvas_webview_ensure/bounds/navigate/action/state/close_all 六个命令 + _cwv.log 诊断(约 250 行)
- 前端:src/canvas-webview.js(463 行)+ build.js 模块登记(89 → 88)
- 插件 browser:节点类型 web 与 nodeTypes 能力(1.1.1 → 1.2.0,市场已更新)

保留(与本功能无关的独立修复):save_geom/restore_geom/托盘/单实例改用 get_window。

版本 3.25.27
2026-11-19 00:11:47 +08:00

41 lines
1.4 KiB
TOML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
[package]
name = "image-workbench"
version = "3.25.27"
description = "无限画布 · 生图工作台桌面版"
authors = ["malongan"]
license = ""
repository = ""
edition = "2024"
rust-version = "1.90"
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
[lib]
name = "image_workbench_lib"
crate-type = ["staticlib", "cdylib", "rlib"]
[build-dependencies]
tauri-build = { version = "2.7.4", features = [] }
[dependencies]
serde_json = "1.0"
serde = { version = "1.0", features = ["derive"] }
log = "0.4"
# tray-icon:系统托盘(关闭窗口收进托盘而不是退出)
# tray-icon:系统托盘;image-png:托盘用单色 PNG 模板图标
# unstable:`Manager::get_window`(窗口级句柄,不受子 webview 影响)与 Window::add_child 都在它下面。
# 画布内嵌网页已下线(v3.25.27),但 get_window 仍要留着 —— save_geom/托盘/单实例都靠它,
# 且它比 get_webview_window 更稳(后者一旦窗口里有非同名 webview 就返回 None,见 v3.25.26)。
tauri = { version = "2.12.5", features = ["tray-icon", "image-png", "unstable"] }
url = "2"
tauri-plugin-log = "2"
tauri-plugin-dialog = "2"
tauri-plugin-fs = "2"
tauri-plugin-http = "2"
tauri-plugin-updater = "2"
tauri-plugin-single-instance = "2"
tauri-plugin-notification = "2"
arboard = "3"
image = { version = "0.25", default-features = false, features = ["png"] }
base64 = "0.22"