Skip to content
Browse files

emit escape event

  • Loading branch information...
1 parent c1737db commit da2661a1e2d5af7546cd09f4a2fd2ed339d77e18 @pgherveou pgherveou committed Jul 7, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/components/dialog/dialog.js
View
2 lib/components/dialog/dialog.js
@@ -1,4 +1,3 @@
-
/**
* Active dialog.
*/
@@ -165,6 +164,7 @@ Dialog.prototype.escapable = function(){
$(document).bind('keydown.dialog', function(e){
if (27 != e.which) return;
$(this).unbind('keydown.dialog');
+ self.emit('escape');
self.hide();
});
};

0 comments on commit da2661a

Please sign in to comment.
Something went wrong with that request. Please try again.