OnNcLButtonUp事件 好像不起作用阿,捕捉不到,一定要用钩子吗?

解决方案 »

  1.   

    可以的吧
    我没试过,但看msdn上的资料好像可以的
    void OnNcLButtonUp( UINT nHitTest, CPoint point );The framework calls this member function when the user releases the left mouse button while the cursor is within a nonclient area. 
      

  2.   

    是不是在窗口外面?用SetCapture()。
      

  3.   

    SetCapture()捕获在工作区外面
    记得ReleaseCapture()
      

  4.   

    如果仅是当前窗口非客户区部份用OnNcLButtonUp()应该没有问题,如果实在不行就用WM_NCHITTEST吧,非客区消息是由这条消息构造的。详细内容请参阅MSDN