title: Windows Touch and Mouse events
body: <p>We have an application built on an older framework (Qt 3.3.5) that we would prefer not to have to attempt to upgrade to recognize touch events.</p>
  
  <p>We recently upgraded it from <code>win32-msvc2005</code> to <code>win32-msvc2013</code>. For the most part this has gone just fine, but tablets (for testing purposes, a Surface Pro on Windows 8.1) that sent mouse events when compiled against 2005 now send only <code>WM_POINTER</code> events when the touch screen is used in the 2013 compiled application.</p>
  
  <p>I have been completely unable to find a way to get Windows to send me mouse events for touchscreen input again. My research implies that if I register for <code>WM_TOUCH</code> events I should <a href="http://the-witness.net/news/2012/10/wm_touch-is-totally-bananas/" rel="nofollow">also get mouse events</a> (as indicated by many people on the internet angry about getting mouse events with their <code>WM_TOUCH</code> events), but my (supposedly) successful calls to <a href="https://msdn.microsoft.com/en-us/library/windows/desktop/dd317326%28v=vs.85%29.aspx" rel="nofollow"><code>RegisterTouchWindow</code></a> don't seem to actually enable the <code>WM_TOUCH</code> events (or any mouse events), and I am still receiving pointer events.</p>
  
  <p>I feel like I must be missing something obvious, especially with not being able to get <code>WM_TOUCH</code> events (which I don't even want, but would supposedly get me mouse events), but whatever it is continues to elude me. (Presumably it would have to be <code>RegisterTouchWindow</code> not being called for the specific <code>hwnd</code> I am actually touching on the screen, but I've gone so far as putting a <code>RegisterTouchWindow</code> call in specifically upon seeing any <code>WM_POINTERUPDATE</code> event for the <code>hwnd</code> that spawned the event, and outputting the result of the Register call upon it returning true and it is returning true, so that seems impossible as the cause.)</p>
  
  <p>I'm also calling <code>DefWindowProc</code> on all <code>WM_TOUCH/GESTURE/POINTER</code> events, which is the only other thing the internet seems to think might be necessary for events to bubble into more basic events correctly. The framework does not call <code>RegisterRawInputDevices</code> and does not attempt to handle <code>WM_INPUT</code> events (which it wouldn't receive anyway thanks to not being registered for raw input). Any events not handled explicitly should fall through to a <code>DefWindowProc</code> call.</p>
  
  <p>Is there even a way that older applications like ours can move to a newer msvc without going through the pain of teaching the framework to correctly handle the various touch protocols? How does an application that worked just fine on msvc2005 using the built in windows touch to mouse events conversion get that functionality back in msvc2013?</p>