Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/398.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript GSAP可通过多个触发器拖动?_Javascript_Gsap - Fatal编程技术网

Javascript GSAP可通过多个触发器拖动?

Javascript GSAP可通过多个触发器拖动?,javascript,gsap,Javascript,Gsap,如果我创建了两个拖曳物,只有最后一个会粘住。在同一个对象上有多个触发器吗 你能为这个做一把小提琴吗? $(".foo").each(function() { Draggable.create(this, { trigger: $(this).find(".a4") }); Draggable.create(this, { type: 'rotation', trigger: $(this).find(".a0, .a2, .a6, .a8"), cur

如果我创建了两个拖曳物,只有最后一个会粘住。在同一个对象上有多个触发器吗


你能为这个做一把小提琴吗?
$(".foo").each(function() {
  Draggable.create(this, {
    trigger: $(this).find(".a4")
  });
  Draggable.create(this, {
    type: 'rotation',
    trigger: $(this).find(".a0, .a2, .a6, .a8"),
    cursor: 'alias'
  });
});