Search and Top Navigation
#7466 closed bug (notabug)
Opened June 11, 2011 08:56PM UTC
Closed June 12, 2011 12:22PM UTC
Dynamically removing selectees from selectable
| Reported by: | kblomqvist | Owned by: | |
|---|---|---|---|
| Priority: | minor | Milestone: | 1.9.0 |
| Component: | ui.selectable | Version: | 1.8.13 |
| Keywords: | Cc: | ||
| Blocked by: | Blocking: |
Description
See comments below ...
$(".selectable").selectable({
selected: function(event, ui) {
// I would like to have the next selectee to be not selectable. Unfortunately
// this is not working as expected. The next one is still selectable by the single click.
// However drag selecting correctly recognizes that this selectee has been disabled.
$(ui.selected).next("li").removeClass("ui-selectee");
},
stop: function() {
// Recalculate the position and size of each selectee
$(this).selectable('refresh');
}
});
Attachments (0)
Change History (1)
Changed June 12, 2011 12:22PM UTC by comment:1
| resolution: | → invalid |
|---|---|
| status: | new → closed |
The ui-selectee class is not what makes an item selectable, it's a side-effect, for theming. What makes an element selectable is it matching the filter option. http://docs.jquery.com/UI/Selectable#option-filter . Until you've confirmed a bug exists, please discuss on the forum http://forum.jquery.com/using-jquery-ui and when you do so, please share a working minimal example using jsbin.com or jsfiddle.net