* submit new map form on Enter - fixes #555 * update divs too
This commit is contained in:
parent
6c22ebcc51
commit
872ae90832
1 changed files with 4 additions and 0 deletions
|
@ -216,6 +216,10 @@ Metamaps.GlobalUI.CreateMap = {
|
|||
bindFormEvents: function () {
|
||||
var self = Metamaps.GlobalUI.CreateMap;
|
||||
|
||||
$('.new_map input, .new_map div').unbind('keypress').bind('keypress', function(event) {
|
||||
if (event.keyCode === 13) self.submit()
|
||||
})
|
||||
|
||||
$('.new_map button.cancel').unbind().bind('click', function (event) {
|
||||
event.preventDefault();
|
||||
Metamaps.GlobalUI.closeLightbox();
|
||||
|
|
Loading…
Reference in a new issue