This is a migrated thread and some comments may be shown as answers.

Jquery touch event lag in kendo mobile q3?

4 Answers 141 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
kory
Top achievements
Rank 1
kory asked on 04 Dec 2012, 03:02 PM
 I have noticed a huge performance hit on my kendo mobile app after updating my code to q3 kendo mobile. My jQuery menu is triggered with mousedown. Since the update on an android device (galaxy note s2), It takes several taps to get a click to register. When I switch back down to Kendo 2012.2 I don't have the issue. Is this the same problem or am I doing something else wrong?

Please see attached.

Note works fine on my desktops browser. I only notice the issue when rendered on the device. 

Thanks for all your help, 
Kendo ui rocks!

4 Answers, 1 is accepted

Sort by
0
Petyo
Telerik team
answered on 04 Dec 2012, 03:51 PM
Hello kory,

I would like to recommend binding to the touchend event instead - in general it provides faster response than the generated mouse events on a mobile device.  

Kind regards,
Petyo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
kory
Top achievements
Rank 1
answered on 04 Dec 2012, 04:37 PM
If I replace mousedown with touchend in my Jquery code as suggested, my menu stops working entirely, though I can hear the touch input sound on the device firing on touchend (I can hear it fire also when using mousedown also). Again this is only on the device not through a browser. If roll back to a previous version (q2) the problem goes away.
0
Petyo
Telerik team
answered on 05 Dec 2012, 12:49 PM
Hello,

I upgraded your project, and tested it in both iOS and Android (attached is a short clip from the iOS Simulator, which in general is quite reliable and matches the iPhone behavior). 

It seems working to me. What am I missing? 

Regards,
Petyo
the Telerik team
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0
kory
Top achievements
Rank 1
answered on 06 Dec 2012, 03:52 PM
Thanks for taking a look , You were right about using touchend in stead my syntax was just slightly off. I had originally tried to just switch out mousedown for touchend which was just a little off, thanks for your help!

After making the change I noticed that all sub nav > ul > li anchor tags displayed the same behavior still (reluctant to click) so i added this simple jquery to bind all anchor tags to the touchend event as well which fixed all buggyness with the sub elements too. 

<script>
$('a').each(function() {
$(this).bind("touchend", function() {
window.location.href = $(this).attr('href');
});
});
</script>


Anyways thanks for your help Petyo you have really been an asset .

Kory Thompson
Tags
General Discussions
Asked by
kory
Top achievements
Rank 1
Answers by
Petyo
Telerik team
kory
Top achievements
Rank 1
Share this question
or