Wpf Touch sometimes clicks random on locations

MatriXz 1 Reputation point


Our system has a list of elements who all have their own separate Mouse and touch events. So when you click or touch one, it opens a new dialog.
There are also elements that do not have any of these click or touch events in the same row.

The click works perfectly so nevermind that.
Touching works if you do it carefully and with lots of patience. One Touch event at a time, and waiting for things to open and load etc. If you start touching faster and impatient, then it "sometimes" opens something in a totally different part of the list, almost randomly.

Or if you touch the elements without the events fast after eachother.
My collegue has attempted almost all things that are easy to find, of solutions on the web.

  • removing mouse events -> touch works perfectly after this, but we need mouse also, so its not a solution.
  • add Telerik features -> no difference.
  • using preview touch events, to get the method to happen before the actual touch or mouse events trigger -> no difference.
  • etc.

Can someone give us some more possible solutions to try, links and or examples would be much appreciated.

Windows Presentation Foundation
Windows Presentation Foundation
A part of the .NET Framework that provides a unified programming model for building line-of-business desktop applications on Windows.
2,191 questions
{count} votes

1 answer

Sort by: Most helpful
  1. MatriXz 1 Reputation point

    We found the bug.

    It seems that "any touch" event will drill down under it's position and mark the views underneath. And we were touching a "close window X" on a popup window, and sometimes you miss and hit something without a handler.
    Then when you randomly click around to test things, the view under the "accidental click" was triggered..

    By removing touch all together and allowing it to bouble down into a mouse click, it will do things correctly, even when you start touching the screen.

    No comments