From: Vincent Vanwaelscappel Date: Tue, 27 Jun 2017 15:16:40 +0000 (+0200) Subject: fix #1505 @1 X-Git-Url: http://git.cubedesigners.com/?a=commitdiff_plain;h=33aef5a92698bb96b7343c75f48d1a1567319128;p=fluidbook-html5.git fix #1505 @1 --- diff --git a/js/main.js b/js/main.js index 566df181..598192ef 100644 --- a/js/main.js +++ b/js/main.js @@ -285,6 +285,20 @@ try { function initEvents() { resize(true); + if (DATAS.preventRightClick) { + $(document).on('contextmenu', function () { + return false; + }); + + $(document).mousedown(function (e) { + if (e.button == 2) { + return false; + } else { + return true; + } + }); + } + $(window).bind('hashchange', function () { if (maskHashChange) { return; @@ -379,7 +393,7 @@ try { return false; }); - $(document).on('click', 'a', function () { + $(document).on('click', 'a', function () { if (!DATAS.phonegap) { return true; } diff --git a/style/fluidbook.less b/style/fluidbook.less index 86d54c55..8ff1038a 100644 --- a/style/fluidbook.less +++ b/style/fluidbook.less @@ -68,6 +68,11 @@ img { -webkit-box-sizing: content-box; -ms-box-sizing: content-box; -o-box-sizing: content-box; + + -webkit-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; } b, strong, h1, h2, h3, h4, h5, h6 { @@ -1423,9 +1428,22 @@ ul.chapters.shareList a.level0 img { .mview .multimediaContainer { padding: 0; + position: relative; + &:after { + content: ''; + position: absolute; + z-index: 2; + width: 100%; + height: 100%; + top: 0; + left: 0; + pointer-events: auto; + } } .mview img.multimedia { + position: relative; + z-index: 1; width: 100%; height: auto; display: block;