# HG changeset patch # User sl # Date 1419849933 -3600 # Node ID bd068db7779a4fe0de13489ac0d471e6287da904 # Parent cbddac7b53e766c131b4082f739efed56c9f88d1 Consolidation and adding rebracer settings. diff -r cbddac7b53e7 -r bd068db7779a HidDevice.cs --- a/HidDevice.cs Sun Dec 28 22:37:21 2014 +0100 +++ b/HidDevice.cs Mon Dec 29 11:45:33 2014 +0100 @@ -26,7 +26,7 @@ public HidDevice(IntPtr hRawInputDevice) { //Fetch various information defining the given HID device - Name = Win32.RawInput.GetDeviceName(hRawInputDevice); + Name = Win32.Utils.RawInput.GetDeviceName(hRawInputDevice); //Open our device from the device name/path SafeFileHandle handle=Win32.Function.CreateFile(Name, diff -r cbddac7b53e7 -r bd068db7779a HidEvent.cs --- a/HidEvent.cs Sun Dec 28 22:37:21 2014 +0100 +++ b/HidEvent.cs Mon Dec 29 11:45:33 2014 +0100 @@ -104,14 +104,14 @@ { //Fetch raw input RAWINPUT rawInput = new RAWINPUT(); - if (!RawInput.GetRawInputData(aMessage.LParam, ref rawInput, ref rawInputBuffer)) + if (!Win32.Utils.RawInput.GetRawInputData(aMessage.LParam, ref rawInput, ref rawInputBuffer)) { return; } //Fetch device info RID_DEVICE_INFO deviceInfo = new RID_DEVICE_INFO(); - if (!RawInput.GetDeviceInfo(rawInput.header.hDevice, ref deviceInfo)) + if (!Win32.Utils.RawInput.GetDeviceInfo(rawInput.header.hDevice, ref deviceInfo)) { return; } @@ -129,7 +129,7 @@ UsagePage = deviceInfo.hid.usUsagePage; UsageCollection = deviceInfo.hid.usUsage; - preParsedData = RawInput.GetPreParsedData(rawInput.header.hDevice); + preParsedData = Win32.Utils.RawInput.GetPreParsedData(rawInput.header.hDevice); if (!(rawInput.hid.dwSizeHid > 1 //Make sure our HID msg size more than 1. In fact the first ushort is irrelevant to us for now && rawInput.hid.dwCount > 0)) //Check that we have at least one HID msg @@ -211,7 +211,8 @@ Marshal.FreeHGlobal(preParsedData); } - if (Usages.Count>0 && Usages[0] != 0) + // + if (IsButtonDown) { StartRepeatTimer(iRepeatDelay); } diff -r cbddac7b53e7 -r bd068db7779a RawInput.cs --- a/RawInput.cs Sun Dec 28 22:37:21 2014 +0100 +++ b/RawInput.cs Mon Dec 29 11:45:33 2014 +0100 @@ -3,7 +3,7 @@ using System.Diagnostics; -namespace Win32 +namespace Win32.Utils { /// /// Provide some utility functions for raw input handling. @@ -54,9 +54,8 @@ /// /// /// - /// - /// - /// + /// + /// /// public static bool GetDeviceInfo(IntPtr hDevice, ref RID_DEVICE_INFO deviceInfo) { diff -r cbddac7b53e7 -r bd068db7779a Rebracer.xml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Rebracer.xml Mon Dec 29 11:45:33 2014 +0100 @@ -0,0 +1,119 @@ + + + + + + + + + + + + + TODO:2 + HACK:2 + UNDONE:2 + UnresolvedMergeConflict:3 + + true + true + false + + + + + 1 + 1 + 2 + 80 + 1 + 1 + 1 + 0 + 1 + 0 + 1 + 1 + 0 + 1 + 1 + 1 + 1 + 0 + 0 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 0 + 1 + 0 + 1 + 0 + 1 + 0 + 0 + 1 + 1 + 1 + 0 + 0 + 1 + 0 + 0 + 0 + 0 + 0 + 1 + 0 + 0 + 0 + 0 + 0 + 0 + 0 + 1 + 1 + 0 + 0 + 1 + 1 + + + false + true + true + true + true + Implicit (Windows)|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\libhelp.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\sitetypesWindows.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\domWindows.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\underscorefilter.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\showPlainComments.js;Implicit (Web)|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\libhelp.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\sitetypesWeb.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\domWeb.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\underscorefilter.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\showPlainComments.js|~/Scripts/_references.js;Dedicated Worker|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\libhelp.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\dedicatedworker.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\underscorefilter.js|C:\Program Files (x86)\Microsoft Visual Studio 11.0\JavaScript\References\showPlainComments.js; + true + true + true + false + true + true + false + false + true + true + + + false + false + true + false + true + true + false + + + + \ No newline at end of file diff -r cbddac7b53e7 -r bd068db7779a RemoteControlSample.sln --- a/RemoteControlSample.sln Sun Dec 28 22:37:21 2014 +0100 +++ b/RemoteControlSample.sln Mon Dec 29 11:45:33 2014 +0100 @@ -3,6 +3,11 @@ # Visual Studio 2012 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "RemoteControlSample", "RemoteControlSample.csproj", "{F676C5E5-266C-439A-98C4-EF21CB9957F2}" EndProject +Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{E70B5E73-7045-4EA7-968D-06BB68773DAB}" + ProjectSection(SolutionItems) = preProject + Rebracer.xml = Rebracer.xml + EndProjectSection +EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|x86 = Debug|x86