I am trying to debug some complex code in which some UI gets created in an iPhone phonegap application.
The problem is that it would seem that when I press the element the event handlers (that are supposedly) attached to its touchstart
event don't fire.
Its either that for some reasons those events are not really attached, or the click gets blocked before reaching them somehow...
I am trying to debug this situation and was wondering:
Given a jQuery object, is the a way to list the event handlers attached to it (via jQuery) for debugging purposes?
Is there an easy way to override
.on
and have itconsole.log
its parametersany other ideas on how I should approach such a problem
UPDATE:
After validating that indeed the element has the touchstart
handler and it is not being called I have discovered that if I am adding click or mousedown
event handlers they do get called.
I suspect this is caused partly by jQuery mobile but I am not sure how or why and why it effects only part of my controls (those are not JQM controls...).