예제 #1
0
        internal static MouseEventExtArgs FromRawDataApp(CallbackData data)
        {
            var wParam = data.WParam;
            var lParam = data.LParam;

            AppMouseStruct marshalledMouseStruct = (AppMouseStruct)Marshal.PtrToStructure(lParam, typeof(AppMouseStruct));

            return(FromRawDataUniversal(wParam, marshalledMouseStruct.ToMouseStruct()));
        }
예제 #2
0
        /// <summary>
        /// Creates <see cref="MouseEventExtArgs"/> from Windows Message parameters,
        /// based upon a local application hook.
        /// </summary>
        /// <param name="wParam">The first Windows Message parameter.</param>
        /// <param name="lParam">The second Windows Message parameter.</param>
        /// <returns>A new MouseEventExtArgs object.</returns>
        private static MouseEventExtArgs FromRawDataApp(int wParam, IntPtr lParam)
        {
            AppMouseStruct marshalledMouseStruct = (AppMouseStruct)Marshal.PtrToStructure(lParam, typeof(AppMouseStruct));

            return(FromRawDataUniversal(wParam, marshalledMouseStruct.ToMouseStruct()));
        }