예제 #1
0
 public static extern int CallNextHookEx(IntPtr hhk, int nCode, IntPtr wParam, ref Message m);
예제 #2
0
 public static extern bool TranslateMessage(ref Message m);
예제 #3
0
        private void DecodeGesture(ref Message message)
        {
            Win32.GESTUREINFO pGestureInfo = new Win32.GESTUREINFO();
            pGestureInfo.cbSize = this.mdGestureInfoSize;
            if (Win32.GetGestureInfo(message.lparam, ref pGestureInfo))
            {
                switch (pGestureInfo.dwID)
                {
                    case 1:
                    case 2:
                        Win32.DefWindowProc(base.hWnd, message.msg, message.lparam, message.wparam);
                        break;

                    case 3:
                        this.DecodeZoomGesture(ref pGestureInfo);
                        break;

                    case 4:
                        this.DecodePanGesture(ref pGestureInfo);
                        break;

                    case 5:
                        this.DecodeRotateGesture(ref pGestureInfo);
                        break;

                    case 6:
                        this.DecodeTwoFingerTapGesture(ref pGestureInfo);
                        break;

                    case 7:
                        this.DecodePressAndTapGesture(ref pGestureInfo);
                        break;
                }
                Win32.CloseGestureInfoHandle(message.lparam);
            }
        }