1
0
Fork 0
forked from 0x2620/oxjs

allow for editing of alternative names

This commit is contained in:
rolux 2011-05-30 10:46:12 +02:00
commit c99e7af1bd
4 changed files with 37 additions and 19 deletions

View file

@ -337,7 +337,10 @@ Ox.Element = function() {
].indexOf(event) == -1) {
Ox.print(that.id, self.options.id, 'trigger', event, data);
}
self.$eventHandler.trigger('ox_' + event, data);
// it is necessary to check if self.$eventHandler exists,
// since, for example, when removing the element on click,
// singleclick will fire after the removal of the event handler
self.$eventHandler && self.$eventHandler.trigger('ox_' + event, data);
});
return that;
};