aboutsummaryrefslogtreecommitdiffstats
path: root/src/jqLite.js
diff options
context:
space:
mode:
authorAndres Ornelas2010-08-04 11:45:42 -0700
committerAndres Ornelas2010-08-04 11:45:42 -0700
commitec12285c9d213a50b86b2ff8d968686acd6d1693 (patch)
tree94c0792946bfa461c4fab525b3758b06c6da9f9f /src/jqLite.js
parentef88eb9a71ee7666029c4fb5eb731ce2e986cecc (diff)
parent89245f3a527415a80d46b37054b558454c314532 (diff)
downloadangular.js-ec12285c9d213a50b86b2ff8d968686acd6d1693.tar.bz2
Merge branch 'master' of github.com:angular/angular.js into future
Diffstat (limited to 'src/jqLite.js')
-rw-r--r--src/jqLite.js17
1 files changed, 6 insertions, 11 deletions
diff --git a/src/jqLite.js b/src/jqLite.js
index cff9ae00..22b3c070 100644
--- a/src/jqLite.js
+++ b/src/jqLite.js
@@ -104,19 +104,14 @@ JQLite.prototype = {
eventHandler = bind[type];
if (!eventHandler) {
bind[type] = eventHandler = function(event) {
- var bubbleEvent = false;
- foreach(eventHandler.fns, function(fn){
- bubbleEvent = bubbleEvent || fn.call(self, event);
- });
- if (!bubbleEvent) {
- if (msie) {
+ if (!event.preventDefault) {
+ event.preventDefault = function(){
event.returnValue = false;
- event.cancelBubble = true;
- } else {
- event.preventDefault();
- event.stopPropagation();
- }
+ };
}
+ foreach(eventHandler.fns, function(fn){
+ fn.call(self, event);
+ });
};
eventHandler.fns = [];
addEventListener(element, type, eventHandler);