openhab/openhab — pull request #807 by maihacke (2014-01-29 21:30:26+00:00)
Title: Fix #799 (prevent multiple events for touchdevices)

Touch devices send both touch and mouse events (see http://www.html5rocks.com/en/mobile/touchandmouse/?redirect_from_locale=de)
The current implementation bind javascript events for both touch and mouse events. This leads to problems because this leads to a double click when pressing buttons on touchdevices.
The solution is to suppress the mouse event on touchdevices (see http://stackoverflow.com/questions/13655919/how-to-bind-both-mousedown-and-touchstart-but-not-respond-to-both-android-jqu)

I changed the implementation for all touch events and added touchevents.
Rollershutters (see #799) are working now on iOS. The other controlls are untested, but should work ;-)
Maybe somebody could test this on android, to make sure it works as expected.

The code is a little redundant at the moment and could be cleaned up at a later time.