diff --git a/IPython/html/static/widgets/js/widget.js b/IPython/html/static/widgets/js/widget.js
index 3d2e1f108..87522855c 100644
--- a/IPython/html/static/widgets/js/widget.js
+++ b/IPython/html/static/widgets/js/widget.js
@@ -304,8 +304,8 @@ function(WidgetManager, _, Backbone){
// TODO: this is hacky, and makes the view depend on this cell attribute and widget manager behavior
// it would be great to have the widget manager add the cell metadata
// to the subview without having to add it here.
- var child_view = this.model.widget_manager.create_view(child_model, options || {}, this);
- child_view.id = child_view.id || IPython.utils.uuid();
+ options = $.merge({ parent: this }, options || {});
+ var child_view = this.model.widget_manager.create_view(child_model, options, this);
// Associate the view id with the model id.
if (this.child_model_views[child_model.id] === undefined) {
@@ -318,7 +318,7 @@ function(WidgetManager, _, Backbone){
return child_view;
},
- delete_child_view: function(child_model, options) {
+ pop_child_view: function(child_model) {
// Delete a child view that was previously created using create_child_view.
var view_ids = this.child_model_views[child_model.id];
if (view_ids !== undefined) {
diff --git a/IPython/html/static/widgets/js/widget_container.js b/IPython/html/static/widgets/js/widget_container.js
index 95e519d35..57d265027 100644
--- a/IPython/html/static/widgets/js/widget_container.js
+++ b/IPython/html/static/widgets/js/widget_container.js
@@ -50,7 +50,7 @@ define(["widgets/js/widget"], function(WidgetManager) {
remove_child_model: function(model) {
// Called when a model is removed from the children list.
- this.delete_child_view(model).remove();
+ this.pop_child_view(model).remove();
},
add_child_model: function(model) {
@@ -254,7 +254,7 @@ define(["widgets/js/widget"], function(WidgetManager) {
remove_child_model: function(model) {
// Called when a child is removed from children list.
- this.delete_child_view(model).remove();
+ this.pop_child_view(model).remove();
},
add_child_model: function(model) {
diff --git a/IPython/html/static/widgets/js/widget_selectioncontainer.js b/IPython/html/static/widgets/js/widget_selectioncontainer.js
index fc35596e0..651a631b2 100644
--- a/IPython/html/static/widgets/js/widget_selectioncontainer.js
+++ b/IPython/html/static/widgets/js/widget_selectioncontainer.js
@@ -92,7 +92,7 @@ define(["widgets/js/widget"], function(WidgetManager){
this.containers.splice(accordion_group.container_index, 1);
delete this.model_containers[model.id];
accordion_group.remove();
- this.delete_child_view(model);
+ this.pop_child_view(model);
},
add_child_model: function(model) {
@@ -190,7 +190,7 @@ define(["widgets/js/widget"], function(WidgetManager){
remove_child_model: function(model) {
// Called when a child is removed from children list.
- var view = this.delete_child_view(model);
+ var view = this.pop_child_view(model);
this.containers.splice(view.parent_tab.tab_text_index, 1);
view.parent_tab.remove();
view.parent_container.remove();