大佬教程收集整理的这篇文章主要介绍了如何使用jQuery UI以编程方式选择可选项?,大佬教程大佬觉得挺不错的,现在分享给大家,也给大家做个参考。
我想要的是告诉它“选择这些家伙”,然后让所有的事件都被正常触发,所以我不必手动调用所有这些选择事件。
更多信息:我谈到的事件是their api和their demo page中列出的事件:
>选择
>选择
>开始
>停止
>未选择
>取消选择
function SELEctSELEctableElements (SELEctableContainer,elementsToSELEct) { // add unSELEcTing class to all elements in the styleboard canvas except the ones to SELEct $(".ui-SELEcted",SELEctableContainer).not(elementsToSELEct).removeClass("ui-SELEcted").addClass("ui-unSELEcTing"); // add ui-SELEcTing class to the elements to SELEct $(elementsToSELEct).not(".ui-SELEcted").addClass("ui-SELEcTing"); // trigger the mouse stop event (this will SELEct all .ui-SELEcTing elements,and deSELEct all .ui-unSELEcTing elements) SELEctableContainer.data("SELEctable")._mouseStop(null); }
更新:
jQueryUI 1.10,来自kmk:http://jsfiddle.net/XYJEN/163/的评论
以上是大佬教程为你收集整理的如何使用jQuery UI以编程方式选择可选项?全部内容,希望文章能够帮你解决如何使用jQuery UI以编程方式选择可选项?所遇到的程序开发问题。
如果觉得大佬教程网站内容还不错,欢迎将大佬教程推荐给程序员好友。
本图文内容来源于网友网络收集整理提供,作为学习参考使用,版权属于原作者。
如您有任何意见或建议可联系处理。小编QQ:384754419,请注明来意。