Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

隐藏程序运行错误窗口 #223

Open
joezhouchenye opened this issue Feb 6, 2024 · 2 comments
Open

隐藏程序运行错误窗口 #223

joezhouchenye opened this issue Feb 6, 2024 · 2 comments
Assignees

Comments

@joezhouchenye
Copy link

启动时会跳出程序运行错误窗口,但不影响实际使用

建议增加winetricks nocrashdialog

目前去掉--rm选项,在容器中修改后,后续通过启动创建的容器的方式运行,没有问题

@huan
Copy link
Owner

huan commented Feb 6, 2024

Thanks for sharing!

I'd love to accept a Pull Request for it.

@huan huan self-assigned this Feb 6, 2024
@joezhouchenye
Copy link
Author

回复晚了,不过我已经不用DoChat了,新的wine 9,源码重新编译,透明框遗留的问题解决了,也没这个报错。主要是最近需要发送文档,DoChat不能拖拽进取实在不能接受。

不过之前尝试了一下,在Dockerfile中添加winetricks nocrashdialog无效,不管使用root还是user用户,wine的注册表始终无法被更改。

以下方法可行。

container_rroot/dochat/目录下增加一个nocrashdialog.sh:

#!/usr/bin/env bash
set -eo pipefail

tmpRegFile=$(mktemp /tmp/regedit.XXXXXXXXX.reg)
trap 'rm -f "$tmpRegFile"' EXIT

cat <<_EOF_ > "$tmpRegFile"
Windows Registry Editor Version 5.00

[HKEY_CURRENT_USER\Software\Wine\WineDbg]
"ShowCrashDialog"=dword:00000000
_EOF_

#
# Setup Wine nocrashdialog in Windows Registry
#
wine regedit.exe /s "$tmpRegFile"

实际作用和wintricks nocrashdialog相同,就是修改注册表,但是似乎只能在wine运行起来过后才有用,构建image的时候无效。

然后在entrypoint.sh中,startWechat函数里面增加

image

重新编译成image,dochat.sh里面修改image后测试没有问题。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants