diff --git a/src/event/input/dispatch.js b/src/event/input/dispatch.js index c6f84582..00e33c0f 100644 --- a/src/event/input/dispatch.js +++ b/src/event/input/dispatch.js @@ -115,8 +115,10 @@ exports.clearOverState = function (id) { if (evt) { delete exports._activeInputOver[id]; var trace = evt.trace; - for (var i = 0, view; view = trace[i]; ++i) { - view.__input.onLeave(id); + if (trace) { + for (var i = 0, view; view = trace[i]; ++i) { + view.__input.onLeave(id); + } } } } else {