swipe coolidates with button

3 posts, 0 answers
  1. Mark
    Mark avatar
    14 posts
    Member since:
    Jul 2013

    Posted 24 Sep 2014 Link to this post

    Hi,

    we have a view (detailedView) with an image button. The image is about half of the screen. With the image button you can navigate to another view (imageGallery)
    <p><a class="imageGallery-button" data-role="button" href="imageGallery.html?id=#=id#">
           <img src="#=imageGallerySplash#" width="100%" /></a>
       </p>

    Also on the detailedView we want to give the possibility to navigate back with a swipe. So if you swipe to the right the app navigates back. This works fine so far.
    $("#is-detailedView").kendoTouch(
               {
                   enableSwipe: true,
                   swipe: function (e) {
               if(e.direction === "right")
               {
                     app.navigateToView("#:back");
                }
           } });

    But the problem arises if you swipe on the image button.
    Then the app navigates back and directly afterwards navigates to the image gallery. It seems that if you start the swipe the button triggers and after the swipe event the app handles the button event.

    Is there any possibility to suppress or cancel button events during the swipe events?

    Thank you and
    Best regards
    Mark
  2. Petyo
    Admin
    Petyo avatar
    2438 posts

    Posted 25 Sep 2014 Link to this post

    Hello Mark,

    there are several means to work around that problem, but before we move into that, I would like to ask you if you are using the latest version of Kendo UI. One or two releases ago, we refined the app navigation behavior, and the buttons no longer navigate when swiped. Please let me know the exact Kendo UI version you are using, so that we may rule that out as an option. 

    Regards,
    Petyo
    Telerik
     
    Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
     
  3. Kendo UI is VS 2017 Ready
  4. Mark
    Mark avatar
    14 posts
    Member since:
    Jul 2013

    Posted 25 Sep 2014 in reply to Petyo Link to this post

    Hi,

    perfect. Updating to the latest version solved the problem. Before we had 2014.1.xxx and with the latest version it works like a charm.

    Thank you very much

    Best regards.
    Mark
Back to Top