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

如何设置动作在任务栏上的图标,比如webview2打开一个网页,在任务栏还是quicker图标 #2093

Open
mxdlzg opened this issue Apr 21, 2024 · 2 comments
Labels

Comments

@mxdlzg
Copy link

mxdlzg commented Apr 21, 2024

需求描述
如何设置动作在任务栏上的图标,比如webview2打开一个网页,在任务栏还是quicker图标,开的多了都分不清哪个是哪个了。。

描述你想要的解决方案
对你想要发生的事情进行清晰简洁的描述。

描述您考虑过的替代方案
winAPI可以做的

其他上下文
在此处添加有关功能请求的任何其他上下文或屏幕截图。

@mxdlzg mxdlzg added the 需求 label Apr 21, 2024
@cuiliang
Copy link
Owner

之前试过,没有办法控制,是根据进程exe变的。你说的winAPI是哪个呢?

@mxdlzg
Copy link
Author

mxdlzg commented Apr 21, 2024

看来我想的有点简单了,不知道像webview这种能不能单开进程。
本来还想着像这类api完全可以做的,但是如果都在一个进程下面,那够呛了:
hicon = user32.LoadIconW(0, ctypes.c_int(32512)) # IDI_APPLICATION
SendMessage(hwnd, WM_SETICON, ICON_SMALL, hicon)
SendMessage(hwnd, WM_SETICON, ICON_BIG, hicon)

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

No branches or pull requests

2 participants