don't trigger event after timeout, see #731

This commit is contained in:
rlx 2012-06-30 16:11:29 +00:00
parent e68b1e163b
commit b5d5936e59

View file

@ -121,7 +121,7 @@ Ox.Event = (function() {
*/
that.trigger = function(self) {
var args = arguments, element = this;
self.eventHandlers && setTimeout(function() {
if (self.eventHandlers) {
Ox.forEach(Ox.makeObject(Ox.slice(args, 1)), function(data, event) {
var triggered = event.split('.');
eventHandlers.forEach(function(callback) {
@ -137,7 +137,7 @@ Ox.Event = (function() {
});
});
});
});
}
return that;
};