打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
JQuery UI
JQuery UI - sortable——2
2010-05-17 9:47
  1. 事件  
  2.   
  3. start  
  4.   当排序动作开始时触发此事件。  
  5.   定义:$('.selector').sortable({ start: function(event, ui) { ... } });  
  6.   绑定:$('.selector').bind('sortstart'function(event, ui) { ... });  
  7.   
  8. sort  
  9.   当元素发生排序时触发此事件。  
  10.   定义:$('.selector').sortable({ sort: function(event, ui) { ... } });  
  11.   绑定:$('.selector').bind('sort'function(event, ui) { ... });  
  12.   
  13. change  
  14.   当元素发生排序且坐标已发生改变时触发此事件。  
  15.   定义:$('.selector').sortable({ change: function(event, ui) { ... } });  
  16.   绑定:$('.selector').bind('sortchange'function(event, ui) { ... });  
  17.   
  18. beforeStop  
  19.   当排序动作结束之前触发此事件。此时占位符元素和辅助元素仍有效。  
  20.   定义:$('.selector').sortable({ beforeStop: function(event, ui) { ... } });  
  21.   绑定:$('.selector').bind('sortbeforeStop'function(event, ui) { ... });  
  22.   
  23. stop  
  24.   当排序动作结束时触发此事件。  
  25.   定义:$('.selector').sortable({ stop: function(event, ui) { ... } });  
  26.   绑定:$('.selector').bind('sortstop'function(event, ui) { ... });  
  27.   
  28. update  
  29.   当排序动作结束时且元素坐标已经发生改变时触发此事件。  
  30.   定义:$('.selector').sortable({ update: function(event, ui) { ... } });  
  31.   绑定:$('.selector').bind('sortupdate'function(event, ui) { ... });  
  32.   
  33. receive  
  34.   当一个已连接的sortable对象接收到另一个sortable对象的元素后触发此事件。  
  35.   定义:$('.selector').sortable({ receive: function(event, ui) { ... } });  
  36.   绑定:$('.selector').bind('sortreceive'function(event, ui) { ... });  
  37.   
  38. over  
  39.   当一个元素拖拽移入另一个sortable对象后触发此事件。  
  40.   定义:$('.selector').sortable({ over: function(event, ui) { ... } });  
  41.   绑定:$('.selector').bind('sortover'function(event, ui) { ... });  
  42. out  
  43.   当一个元素拖拽移出sortable对象移出并进入另一个sortable对象后触发此事件。  
  44.   定义:$('.selector').sortable({ out: function(event, ui) { ... } });  
  45.   绑定:$('.selector').bind('sortout'function(event, ui) { ... });  
  46.   
  47. activate  
  48.   当一个有使用连接的sortable对象开始排序动作时,所有允许的sortable触发此事件。  
  49.   定义:$('.selector').sortable({ activate: function(event, ui) { ... } });  
  50.   绑定:$('.selector').bind('sortactivate'function(event, ui) { ... });  
  51.   
  52. deactivate  
  53.   当一个有使用连接的sortable对象结束排序动作时,所有允许的sortable触发此事件。  
  54.   定义:$('.selector').sortable({ deactivate: function(event, ui) { ... } });  
  55.   绑定:$('.selector').bind('sortdeactivate'function(event, ui) { ... });  
  56.   
  57.   
  58. ·方法  
  59. destory  
  60.   从元素中移除拖拽功能。  
  61.   用法:.sortable( 'destroy' )  
  62.   
  63. disable  
  64.   禁用元素的拖拽功能。  
  65.   用法:.sortable( 'disable' )  
  66.   
  67. enable  
  68.   启用元素的拖拽功能。  
  69.   用法:.sortable( 'enable' )  
  70.   
  71. option  
  72.   获取或设置元素的参数。  
  73.   用法:.sortable( 'option' , optionName , [value] )  
  74.   
  75. serialize  
  76.   获取或设置序列化后的每个item元素的id属性。  
  77.   用法:.sortable( 'serialize' , [options] )  
  78.   
  79. toArray  
  80.   获取序列化后的每个item元素的id属性的数组。  
  81.   用法:.sortable( 'toArray' )  
  82.   
  83. refresh  
  84.   手动重新刷新当前sortable对象的item元素的排序。  
  85.   用法:.sortable( 'refresh' )  
  86.   
  87. refreshPositions  
  88.   手动重新刷新当前sortable对象的item元素的坐标,此方法可能会降低性能。  
  89.   用法:.sortable( 'refreshPositions' )  
  90.   
  91. cancel  
  92.   取消当前sortable对象中item元素的排序改变。  
  93.   用法:.sortable( 'cancel' ) 

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
三. jQuery中的事件和动画
jQuery新的事件绑定机制on()
浅谈Jquery中的bind(),live(),delegate(),on()绑定事件方式
jQuery中的bind(), live(), on(), delegate()
javascript – 可拖动和保证金:0自动;
[转]jQuery off() 方法
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服