loleaflet/src/control/Control.PartsPreview.js |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

New commits:
commit 40fb94207e34d46aaba073b09667f53286d0ef0a
Author:     Pranam Lashkari <lpra...@collabora.com>
AuthorDate: Mon Aug 31 18:45:45 2020 +0530
Commit:     Pranam Lashkari <lpra...@collabora.com>
CommitDate: Mon Aug 31 19:21:48 2020 +0200

    leaflet: fixed js error in slide reordering with touch screen
    
    Change-Id: I7e1c864640f5829166616e5bf40b95646d913b23
    Reviewed-on: https://gerrit.libreoffice.org/c/online/+/101736
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com>
    Reviewed-by: Pranam Lashkari <lpra...@collabora.com>

diff --git a/loleaflet/src/control/Control.PartsPreview.js 
b/loleaflet/src/control/Control.PartsPreview.js
index 718d65b50..af553f552 100644
--- a/loleaflet/src/control/Control.PartsPreview.js
+++ b/loleaflet/src/control/Control.PartsPreview.js
@@ -585,7 +585,7 @@ L.Control.PartsPreview = L.Control.extend({
                        e.preventDefault();
                }
 
-               this.currentNode = 
document.elementFromPoint(e.touches[0].clientX, e.touches[0].clientY);
+               this.currentNode = 
document.elementFromPoint(e.originalEvent.touches[0].clientX, 
e.originalEvent.touches[0].clientY);
 
                if (this.currentNode !== this.previousNode && this.previousNode 
!== null) {
                        $('.preview-frame').removeClass('preview-img-dropsite');
@@ -597,8 +597,8 @@ L.Control.PartsPreview = L.Control.extend({
 
                this.previousNode = this.currentNode;
 
-               $(this.draggedSlide).css('left', e.touches[0].clientX - 
(e.target.width/2));
-               $(this.draggedSlide).css('top', e.touches[0].clientY - 
e.target.height);
+               $(this.draggedSlide).css('left', 
e.originalEvent.touches[0].clientX - (e.target.width/2));
+               $(this.draggedSlide).css('top', 
e.originalEvent.touches[0].clientY - e.target.height);
                return false;
        },
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to