Cannot listen for any touch or gestures on embedded pdf

2 posts, 0 answers
  1. Marlon
    Marlon avatar
    16 posts
    Member since:
    Jul 2013

    Posted 19 Sep Link to this post

    Example Dojo:

    I'm trying to allow for pinch/zoom gestures on a pdf that I've embedded into a MobileView but nothing I've tried has allowed me to listen for touchstart/touchend on iOS devices. it took alot of trial an error to devise this solution between browsers using the iframe and mobile safari needing the embed tag to allow for scrolling in the pdf.  I even tried applying a kendo touch to the embed tag on init of the view but that throws a javascript error. What am I doing wrong?

  2. Stefan
    Stefan avatar
    195 posts

    Posted 21 Sep Link to this post

    Hello Marlon,

    After inspecting the provided example, I noticed that if the src attribute is set directly in the HTML, not through the view model the touchstart and touchend events are thrown correctly. I can assume that the issue is caused because when the src attribute is set in a later state via the data-binding, this is causing an issue with the event handlers.

    I modified the example to demonstrate this implementation:

    I hope this will help you to achieve the desired result.

    Telerik by Progress
    Get started with Kendo UI in days. Online training courses help you quickly implement components into your apps.
Back to Top