perf: 优化图片消息后台加载与解密缓存

- 缩略图优先展示并在后台准备原图
- 增加图片请求去重与受控并发队列
- 缓存图片路径、账号目录和解密结果
This commit is contained in:
Wxw-Gu
2026-07-28 16:11:59 +08:00
parent 49684f3365
commit d0ae9e6019
6 changed files with 400 additions and 107 deletions
+1 -1
View File
@@ -61,7 +61,7 @@ const api = {
imageMd5?: string,
imageDatNameOrThumb?: string | boolean,
sessionId?: string,
options?: { force?: boolean }
options?: { force?: boolean; preferThumbnail?: boolean }
) => ipcRenderer.invoke('db:getImage', imageMd5, imageDatNameOrThumb, sessionId, options),
getVideo: (hashes: string[]) => ipcRenderer.invoke('db:getVideo', hashes),
getSticker: (cdnUrl?: string, md5?: string) => ipcRenderer.invoke('db:getSticker', cdnUrl, md5),