Skip to content

Commit

Permalink
Merge pull request visionmedia#54 from pgherveou/patch-3
Browse files Browse the repository at this point in the history
handle confirmation closed through overlay click + unbind keydown
  • Loading branch information
tj committed Jul 11, 2012
2 parents f9903c8 + 3d882ef commit d75189a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/components/dialog/dialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ Dialog.prototype.overlay = function(){
.overlay({ closable: true })
.on('hide', function(){
self.closedOverlay = true;
self.emit('close');
self.hide();
});
return this;
Expand Down Expand Up @@ -248,5 +249,6 @@ Dialog.prototype.hide = function(ms){
Dialog.prototype.remove = function(){
this.emit('hide');
this.el.remove();
$(document).unbind('keydown.dialog');
return this;
};

0 comments on commit d75189a

Please sign in to comment.