From 5c8bbd0a9fad8a0b2a875ba20999f50e841799b2 2014-09-04 22:19:59 From: Matthias Bussonnier Date: 2014-09-04 22:19:59 Subject: [PATCH] Merge pull request #6406 from minrk/celltoolbar-rendered don't hide cell toolbar on rendered text cells --- diff --git a/IPython/html/static/notebook/js/celltoolbar.js b/IPython/html/static/notebook/js/celltoolbar.js index a85c1af..c98c4be 100644 --- a/IPython/html/static/notebook/js/celltoolbar.js +++ b/IPython/html/static/notebook/js/celltoolbar.js @@ -280,7 +280,7 @@ define([ } // If there are no controls or the cell is a rendered TextCell hide the toolbar. - if (!this.ui_controls_list.length || (this.cell.cell_type != 'code' && this.cell.rendered)) { + if (!this.ui_controls_list.length) { this.hide(); } else { this.show(); diff --git a/IPython/html/static/notebook/js/textcell.js b/IPython/html/static/notebook/js/textcell.js index 3f98da6..e599a99 100644 --- a/IPython/html/static/notebook/js/textcell.js +++ b/IPython/html/static/notebook/js/textcell.js @@ -137,9 +137,6 @@ define([ } this.refresh(); } - if (this.celltoolbar.ui_controls_list.length) { - this.celltoolbar.show(); - } return cont; }; @@ -180,7 +177,6 @@ define([ */ TextCell.prototype.set_rendered = function(text) { this.element.find('div.text_cell_render').html(text); - this.celltoolbar.hide(); };