[英]Fabric.js – element is undefined when I move the mouse holding down the mouse button
[英]Selecting/Unselecting checkboxes by holding down the mouse button
我有一组复选框,当您用鼠标选择它时,我想要检查或取消选中(如果选中)。 我并不是指任何普通类型的选择,我的意思是,当您移动复选框/标签时,选择按住鼠标按钮的选定区域中的复选框。
我无法解释这个,所以我做了一个图像示例。
所以,如果我有一组像这样的复选框/标签:
<input type="checkbox" id="i1"/><label for="i1">Jun 23 2012</label>
<input type="checkbox" id="i1"/><label for="i1">Jun 24 2012</label>
<input type="checkbox" id="i1"/><label for="i1">Jun 25 2012</label>
<input type="checkbox" id="i1"/><label for="i1">Jun 26 2012</label>
我该怎么做呢?
我试过看谷歌,但一无所获。 任何帮助表示赞赏。 谢谢。
你最好用
<select size=5 multiple>
问候。
尝试在父div中扭曲内容。然后尝试:
$("#test").selectable({
filter:'label',
stop: function() {
$("input").attr('checked',false);
$(".ui-selected input", this).each(function() {
this.checked= true;
});
}
});
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.