mirror of
https://github.com/fhem/fhem-mirror.git
synced 2025-01-31 18:59:33 +00:00
fhemweb.js: fix slider in dashboard (Forum #16503)
git-svn-id: https://svn.fhem.de/fhem/trunk@9879 2b470e98-0d58-463d-a4d8-8e2adae1ed80
This commit is contained in:
parent
fa8209b443
commit
916148c8d4
@ -827,11 +827,14 @@ FW_createSlider(elName, devName, vArr, currVal, set, params, cmd)
|
||||
var oldFn1 = document.onmousemove, oldFn2 = document.onmouseup,
|
||||
oldFn3 = document.ontouchmove, oldFn4 = document.ontouchend;
|
||||
|
||||
e.stopPropagation(); // Dashboard fix
|
||||
lastX = e.clientX; // Does not work on IE8
|
||||
|
||||
function
|
||||
mouseMove(e)
|
||||
{
|
||||
e.stopPropagation(); // Dashboard fix
|
||||
|
||||
if(maxX == 0) // Forum #35846
|
||||
maxX = slider.offsetWidth-sh.offsetWidth;
|
||||
var diff = e.clientX-lastX; lastX = e.clientX;
|
||||
@ -849,6 +852,7 @@ FW_createSlider(elName, devName, vArr, currVal, set, params, cmd)
|
||||
|
||||
document.onmouseup = document.ontouchend = function(e)
|
||||
{
|
||||
e.stopPropagation(); // Dashboard fix
|
||||
document.onmousemove = oldFn1; document.onmouseup = oldFn2;
|
||||
document.ontouchmove = oldFn3; document.ontouchend = oldFn4;
|
||||
if(cmd)
|
||||
|
Loading…
Reference in New Issue
Block a user