WM_COMMAND 与 WM_SYSCOMMAND 区别(50)

  • 主题发起人 主题发起人 delphi0808
  • 开始时间 开始时间
D

delphi0808

Unregistered / Unconfirmed
GUEST, unregistred user!
1.产生2.处理
 
看一下MSDN的帮助就很清楚了:The WM_COMMAND message is sent when the user selects a command item from a menu, when a control sends a notification message to its parent window, or when an accelerator keystroke is translated. WM_COMMAND wNotifyCode = HIWORD(wParam); // notification code wID = LOWORD(wParam); // item, control, or accelerator identifier hwndCtl = (HWND) lParam; // handle of control WM_SYSCOMMANDA window receives this message when the user chooses a command from the window menu (also known as the System menu or Control menu) or when the user chooses the Maximize button or Minimize button.WM_SYSCOMMAND uCmdType = wParam; // type of system command requested xPos = LOWORD(lParam); // horizontal postion, in screen coordinates yPos = HIWORD(lParam); // vertical postion, in screen coordinates 处理起来,无非就是参数不同而已。
 
后退
顶部