From db53a2358658b5020101f4e5b6d8cd7287e17a6a 2013-08-07 02:30:48 From: MinRK Date: 2013-08-07 02:30:48 Subject: [PATCH] swallow enter event in rename dialog avoids adding newline in cell after dialog is closed. closes #3926 --- diff --git a/IPython/html/static/notebook/js/savewidget.js b/IPython/html/static/notebook/js/savewidget.js index e83399f..e049a71 100644 --- a/IPython/html/static/notebook/js/savewidget.js +++ b/IPython/html/static/notebook/js/savewidget.js @@ -100,6 +100,7 @@ var IPython = (function (IPython) { that.find('input[type="text"]').keydown(function (event, ui) { if (event.which === utils.keycodes.ENTER) { that.find('.btn-primary').first().click(); + return false; } }); that.find('input[type="text"]').focus();