loleaflet/js/global.js |    9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

New commits:
commit 3aa7bec6665565a41595ec14374af079f2df9fc4
Author:     Jan Holesovsky <ke...@collabora.com>
AuthorDate: Fri Aug 7 13:49:32 2020 +0200
Commit:     Jan Holesovsky <ke...@collabora.com>
CommitDate: Fri Aug 7 15:08:55 2020 +0200

    android: Chromebook is not a touch device, avoid using Hammer there.
    
    This fixes the mouse wheel - now it works on the chromebooks.
    
    Change-Id: I5bf2a7e1ae397ef171221ac58172940bb43cbb3c
    Reviewed-on: https://gerrit.libreoffice.org/c/online/+/100310
    Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoff...@gmail.com>
    Reviewed-by: Jan Holesovsky <ke...@collabora.com>

diff --git a/loleaflet/js/global.js b/loleaflet/js/global.js
index c1397ee99..8f5c53c0f 100644
--- a/loleaflet/js/global.js
+++ b/loleaflet/js/global.js
@@ -34,8 +34,10 @@
            gecko3d = 'MozPerspective' in doc.style,
            opera12 = 'OTransition' in doc.style;
 
+       var chromebook = window.ThisIsTheAndroidApp && 
window.LOOLMessageHandler.isChromeOS();
+
        var touch = !window.L_NO_TOUCH && (pointer || 'ontouchstart' in window 
||
-                       (window.DocumentTouch && document instanceof 
window.DocumentTouch));
+                       (window.DocumentTouch && document instanceof 
window.DocumentTouch)) && !chromebook;
 
        var isInternetExplorer = 
(navigator.userAgent.toLowerCase().indexOf('msie') != -1 ||
                        navigator.userAgent.toLowerCase().indexOf('trident') != 
-1);
@@ -160,10 +162,7 @@
 
        global.mode = {
                isChromebook: function() {
-                       if (!window.ThisIsTheAndroidApp)
-                               return false;
-
-                       return window.LOOLMessageHandler.isChromeOS();
+                       return chromebook;
                },
                // Here "mobile" means "mobile phone" (at least for now). Has 
to match small screen size
                // requirement.
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to