From b96dd7bbf61e84be51a7e011a85d1f09f493d1e5 Mon Sep 17 00:00:00 2001 From: Valerio Virgillito Date: Thu, 3 May 2012 23:15:17 -0700 Subject: fixing the currentContainer Signed-off-by: Valerio Virgillito --- js/controllers/elements/element-controller.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'js/controllers') diff --git a/js/controllers/elements/element-controller.js b/js/controllers/elements/element-controller.js index 45d78b33..20225c61 100755 --- a/js/controllers/elements/element-controller.js +++ b/js/controllers/elements/element-controller.js @@ -15,13 +15,13 @@ exports.ElementController = Montage.create(Component, { var selectedLayerIndex = this.application.ninja.timeline.getLayerIndexByID(this.application.ninja.timeline.currentLayerSelected.layerData.layerID); if(selectedLayerIndex === 0) { - this.application.ninja.currentDocument.currentSelectedContainer.appendChild(el); + this.application.ninja.currentSelectedContainer.appendChild(el); } else { var element = this.application.ninja.timeline.arrLayers[selectedLayerIndex].layerData.elementsList[0]; element.parentNode.insertBefore(el, element.nextSibling); } } else { - this.application.ninja.currentDocument.currentSelectedContainer.appendChild(el); + this.application.ninja.currentSelectedContainer.appendChild(el); } if(styles) { -- cgit v1.2.3