From f064f8e11321587d93bc548d7298775bc0e170ef Mon Sep 17 00:00:00 2001 From: Matthias Bussonnier Date: Wed, 14 Jan 2015 11:05:16 +0100 Subject: [PATCH] also fix action in kernelselector.js --- IPython/html/static/notebook/js/kernelselector.js | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/IPython/html/static/notebook/js/kernelselector.js b/IPython/html/static/notebook/js/kernelselector.js index d82200edd..5683c0d4a 100644 --- a/IPython/html/static/notebook/js/kernelselector.js +++ b/IPython/html/static/notebook/js/kernelselector.js @@ -60,7 +60,10 @@ define([ ks = this.kernelspecs[keys[i]]; ks_submenu_entry = $("
  • ").attr("id", "kernel-submenu-"+ks.name).append($('') .attr('href', '#') - .click($.proxy(this.set_kernel, this, ks.name)) + .click(function(){ + $.proxy(this.set_kernel, this, ks.name) + event.preventDefault(); + }) .text(ks.spec.display_name)); change_kernel_submenu.append(ks_submenu_entry); } @@ -70,7 +73,10 @@ define([ ks = this.kernelspecs[keys[i]]; ks_submenu_entry = $("
  • ").attr("id", "new-notebook-submenu-"+ks.name).append($('') .attr('href', '#') - .click($.proxy(this.new_notebook, this, ks.name)) + .click(function(){ + $.proxy(this.new_notebook, this, ks.name) + event.preventDefault(); + }) .text(ks.spec.display_name)); new_notebook_submenu.append(ks_submenu_entry); }