如何显示"NotifyIconOverflowWindow"窗户? [英] how to show "NotifyIconOverflowWindow" window?

查看:123
本文介绍了如何显示"NotifyIconOverflowWindow"窗户?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在某些程序中显示NotifyIconOverflowWindow,但我尝试这样:

I want to show NotifyIconOverflowWindow in some program, and I tried to like this:

pop = FindWindow((LPCWSTR)L"NotifyIconOverflowWindow", (LPCWSTR)"");
ShowWindow(pop, SW_SHOWNORMAL);



但是,如果我不单击任务栏,首先会弹出NotifyIconOverflowWindow.我的程序创建的NotifyIconOverflowWindow中没有任何内容.



But if I do not click taskbar and popup NotifyIconOverflowWindow at first. There is nothing in my NotifyIconOverflowWindow created by my program.

推荐答案

首先,到底是什么?在第一种情况下,它什么都不做(为什么将某些东西转换成已经存在的东西?),在第二种情况下,它是一个bug(像这样的广播不会使狭窄的字符串变成宽字符串).实际上,第二个强制转换可能是问题的起因,因为宽字符串需要两个字节的NULL.试试这个:
Firstly, what the hell is all the casting for? In the first case it does nothing (why cast something to what it already is?) and in the second it''s a bug (casting like this doesn''t make a narrow string a wide one). In fact the second cast is probably the casue of the problem as wide strings need a two byte NULL. Try this:
pop = FindWindow(L"NotifyIconOverflowWindow", NULL);
ShowWindow(pop, SW_SHOWNORMAL);


停止投射!


Stop casting!


看起来像第一次通过任务栏中的三角形按钮弹出窗口时呈现的窗口内容.因此,如果这没有发生,那么以这种方式显示窗口时,您显然会看到一个空白窗口.

不过,您可以尝试向按钮发送鼠标左键,这样一来,您将始终确保窗口显示时可以正确渲染该窗口.
Looks like the window contents are rendered the first time the window is popped up via the triangular button in the task bar. So if that has not happened, then obviously you will see a blank window when you show the window in this manner.

You could try sending a left mouse click to the button though, that way you will always be sure that the window will be properly rendered when it shows up.


这篇关于如何显示"NotifyIconOverflowWindow"窗户?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆