Windows XP中的“仅消息"窗口未收到WM_POWERBROADCAST [英] WM_POWERBROADCAST not received by message-only window in Windows XP

查看:207
本文介绍了Windows XP中的“仅消息"窗口未收到WM_POWERBROADCAST的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试确定是否将广播消息发送到仅消息窗口,即创建为:

I'm trying to find out whether broadcast messages will be sent to message only windows, i.e. created as:

hWnd = CreateWindow(MAKEINTATOM(RegisterClass(&wnd)), NULL, 0, 0, 0, 0, 0, 0, HWND_MESSAGE, hInstance, 0);

问题是我没有收到任何广播消息到该窗口...;)

Thing is that I don't get any broadcast messages to that window... ;)

推荐答案

您的怀疑是正确的.仅消息窗口(通过为CreateWindowEx函数的hwndParent参数指定HWND_MESSAGE创建的窗口)不会接收广播通知:

Your suspicions are correct. Message-only windows (those created by specifying HWND_MESSAGE for the hwndParent parameter of the CreateWindowEx function) do not receive broadcast notifications:

仅邮件窗口,使您可以发送和接收邮件.它不可见,没有z顺序,无法枚举,并且不接收广播消息.窗口只是调度消息.

A message-only window enables you to send and receive messages. It is not visible, has no z-order, cannot be enumerated, and does not receive broadcast messages. The window simply dispatches messages.

参考: MSDN

这篇关于Windows XP中的“仅消息"窗口未收到WM_POWERBROADCAST的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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