修复由于图标路径采用绝对路径,以及图片资源为添加到msi文件导致exe文件无法运行问题

This commit is contained in:
Tlntin
2022-11-22 00:25:57 +08:00
parent c1981f2951
commit 62d89c6fad
2 changed files with 2 additions and 4 deletions

View File

@@ -118,9 +118,7 @@ fn main() -> wry::Result<()> {
})
.with_inner_size(wry::application::dpi::LogicalSize::new(width, height));
#[cfg(target_os = "windows")]
let icon_path = concat!(env!("CARGO_MANIFEST_DIR"), "/png/weread_32.ico");
#[cfg(target_os = "windows")]
let icon = load_icon(std::path::Path::new(icon_path));
let icon = load_icon(std::path::Path::new("png/weread_32.ico"));
#[cfg(target_os = "windows")]
let window = common_window

View File

@@ -52,7 +52,7 @@
"providerShortName": null,
"signingIdentity": null
},
"resources": [],
"resources": ["png/weread_32.ico"],
"shortDescription": "",
"targets": ["deb", "msi", "dmg"],
"windows": {