trigger cut and cutadd events (consumer of list events may want to differentiate between cut and delete)

This commit is contained in:
rlx 2013-08-03 13:57:55 +00:00
parent 989cb2c945
commit 20137da742

View file

@ -39,6 +39,8 @@ Ox.List <f> List constructor
closepreview <!> preview closed
copy <!> copy and replace clipboard
copyadd <!> copy and add to clipboard
cut <!> cut and replace clipboard
cutadd <!> cut and add to clipboard
delete <!> item removed
draganddrop <!> Fires during drag
draganddropend <!> Fires on drop
@ -394,8 +396,9 @@ Ox.List = function(options, self) {
}
function cutItems(add) {
copyItems(add);
deleteItems();
self.options.selected.length && that.triggerEvent('cut' + (add ? 'add' : ''), {
ids: self.options.selected
});
}
function deleteItems() {