JQ UI滑块手柄跳转 [英] JQ UI slider handle jumps

查看:53
本文介绍了JQ UI滑块手柄跳转的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

JQ UI创建垂直滑块的标准方法。这只是在作​​弊时,手柄的高度超过标准(20px),然后当我点击滑块手柄并在任何方向上移动鼠标至少一个像素时 - 滑块的手柄会跳几个像素。我想这样做,不会反弹。提前感谢您的回答。



[HTML]< html lang =en>

< head>

< meta charset =utf-8/>



< script src =http://code.jquery。 com / jquery-1.9.1.js>< / script>

< script src =http://code.jquery.com/ui/1.10.3/jquery-ui .js>< / script>



.ui-slider .ui-slider-handle {

身高:30px;

}



< script>

$(function(){

$(。slider-vertical)。slider({

orientation:vertical,

});

});

< / script>

< / head>

< body>



< / body> [/ HTML]

The standard way to create a vertical slider by JQ UI. That's only if the cheating, the height of the handle more than the standard (20px), then when I click on the slider handle and move the mouse at least one pixel in any direction - the handle of the slider jumps a few pixels. I would like to do so, that does not bounce. Thank you in advance for your answers.

[HTML]<html lang="en">
<head>
<meta charset="utf-8" />

<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="http://code.jquery.com/ui/1.10.3/jquery-ui.js"></script>

.ui-slider .ui-slider-handle{
height: 30px;
}

<script>
$(function() {
$(".slider-vertical").slider({
orientation: "vertical",
});
});
</script>
</head>
<body>

</body> [/HTML]

推荐答案

(function(){
(function() {


(。slider-vertical)。滑块({

方向:垂直,

});

});

< /脚本>

< / head>

< body>



< / body> [/ HTML]
(".slider-vertical").slider({
orientation: "vertical",
});
});
</script>
</head>
<body>

</body> [/HTML]


找到答案。主题已关闭。
The answer is found. Topic is closed.


这篇关于JQ UI滑块手柄跳转的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆