如题,望知道的朋友帮忙解答一下,找了下没有找到这方面的资料。谢谢!
解决方案 »
- 找工作,专长是C++,北京地区,不计较工资,需要的联系我
- 二值图和24位色位图是什么关系啊?
- 如果程序里面有多个从CWnd派生出来的类,是不是每个类都有自己的消息处理过程wndproc??????
- setviewprotextex
- 怎么知道我的可用分?
- 做过截取窗体内容的朋友进来看看这个问题~~~~
- VB中能否使用COM接口传出的结构类型的数据?
- 寻求翻转棋算法(88分)
- MFC程序button类继承,自绘一个按钮,但是按钮不能连续点击,每次要间隔零点几秒才能继续点击。
- 把内存中的BMP图象放到数组
- vc编写调用Htmlhelp的软件,#include"CHMHelp.h"时发现找不到
- 如何让对话框只创建一个实例?
PNOTIFYICONDATA lpdata
);
ParametersdwMessage
[in] A variable of type DWORD that specifies the action to be taken. It can have one of the following values.
NIM_ADD
Adds an icon to the status area. The hWnd and uID members of the NOTIFYICONDATA structure pointed to by lpdata will be used to identify the icon in later calls to Shell_NotifyIcon.
NIM_DELETE
Deletes an icon from the status area. Use the hWnd and uID members of the NOTIFYICONDATA structure pointed to by lpdata to identify the icon to be deleted.
NIM_MODIFY
Modifies an icon in the status area. Use the hWnd and uID members of the NOTIFYICONDATA structure pointed to by lpdata to identify the icon to be modified.
NIM_SETFOCUS
Version 5.0. Returns focus to the taskbar notification area. Taskbar icons should use this message when they have completed their user interface operation. For example, if the taskbar icon displays a shortcut menu, but the user presses ESC to cancel it, use NIM_SETFOCUS to return focus to the taskbar notification area.
NIM_SETVERSION
Version 5.0. Instructs the taskbar to behave according to the version number specified in the uVersion member of the structure pointed to by lpdata. This message allows you to specify whether you want the version 5.0 behavior found on Microsoft Windows 2000 systems, or the behavior found on earlier Shell versions. The default value for uVersion is zero, indicating that the original Windows 95 notify icon behavior should be used. For details, see the Res section.
lpdata
[in] A pointer to a NOTIFYICONDATA structure. The content of the structure depends on the value of dwMessage.
Return ValueReturns TRUE if successful, or FALSE otherwise. If dwMessage is set to NIM_SETVERSION, the function returns TRUE if the version was successfully changed, or FALSE if the requested version is not supported.
You can call GetLastError for more specific information about a failure case. The most common cause of failure is that the taskbar window doesn't exist or is unresponsive. GetLastError in that case returns E_FILE_NOT_FOUND.ResAs of Windows XP Service Pack 2 (SP2), a custom icon can be displayed in the notification balloon. This allows the calling process to customize the notification beyond the previously available options of info, warning, and error, and distinguish it from other types of notification for the user.Version 5.0 of the Shell, found on Windows 2000, and later versions handle Shell_NotifyIcon mouse and keyboard events differently than the earlier Shell versions found on Microsoft Windows NT 4.0, Windows 95, and Windows 98. The differences include the following:
If a user selects a notify icon's shortcut menu with the keyboard, the version 5.0 Shell sends the associated application a WM_CONTEXTMENU message. Earlier versions send WM_RBUTTONDOWN and WM_RBUTTONUP messages.
If a user selects a notify icon with the keyboard and activates it with the SPACEBAR or ENTER key, the version 5.0 Shell sends the associated application an NIN_KEYSELECT notification. Earlier versions send WM_RBUTTONDOWN and WM_RBUTTONUP messages.
If a user selects a notify icon with the mouse and activates it with the ENTER key, the version 5.0 Shell sends the associated application an NIN_SELECT notification. Earlier versions send WM_RBUTTONDOWN and WM_RBUTTONUP messages.
If a user passes the mouse pointer over an icon with which a balloon ToolTip is associated, the version 6.0 Shell (Windows XP) sends the following messages.
NIN_BALLOONSHOW. Sent when the balloon is shown (balloons are queued).
NIN_BALLOONHIDE. Sent when the balloon disappears. For example, when the icon is deleted. This message is not sent if the balloon is dismissed because of a timeout or if the user clicks the mouse.
NIN_BALLOONTIMEOUT. Sent when the balloon is dismissed because of a timeout.
NIN_BALLOONUSERCLICK. Sent when the balloon is dismissed because the user clicked the mouse.
If a user passes the mouse pointer over an icon with which a balloon ToolTip is associated, the Windows Vista Shell adds the following messages.
NIN_POPUPOPEN. Sent when the user hovers the cursor over an icon to indicate that the richer pop-up user interface (UI) should be used in place of a standard textual ToolTip.
NIN_POPUPCLOSE. Sent when a cursor no longer hovers over an icon to indicate that the rich pop-up UI should be closed.You can select which way the Shell should behave by calling Shell_NotifyIcon with dwMessage set to NIM_SETVERSION. Set the uVersion member of the NOTIFYICONDATA structure to indicate whether you want version 5.0 or pre-version 5.0 behavior.Note The messages discussed above are not conventional Windows messages. They are sent as the lParam value of the application-defined message that is specified when the icon is added with NIM_ADD.