From 2b3d6ab2e4992d9802db89ec70ef8f68e5c8f789 Mon Sep 17 00:00:00 2001 From: Jonathan Frederic Date: Thu, 17 Oct 2013 06:10:28 +0000 Subject: [PATCH] Added clear widget area button --- IPython/html/static/notebook/js/codecell.js | 23 +++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) diff --git a/IPython/html/static/notebook/js/codecell.js b/IPython/html/static/notebook/js/codecell.js index 25afa3f05..848735792 100644 --- a/IPython/html/static/notebook/js/codecell.js +++ b/IPython/html/static/notebook/js/codecell.js @@ -133,10 +133,25 @@ var IPython = (function (IPython) { inner_cell.append(input_area); input.append(prompt).append(inner_cell); - var widget_area = $('
').addClass('widget_area'); - var widget_prompt = $('
').addClass('prompt'); - var widget_subarea = $('
').addClass('widget_subarea'); - widget_area.append(widget_prompt).append(widget_subarea); + var widget_area = $('
') + .addClass('widget_area') + .hide(); + this.widget_area = widget_area; + var widget_prompt = $('
') + .addClass('prompt') + .appendTo(widget_area); + var widget_subarea = $('
') + .addClass('widget_subarea') + .appendTo(widget_area); + this.widget_subarea = widget_subarea; + var widget_clear_buton = $('