diff options
author | Jonathan Duran | 2012-05-09 09:58:27 -0700 |
---|---|---|
committer | Jonathan Duran | 2012-05-09 09:58:27 -0700 |
commit | 48a2a800155fd2d608fb7191c0180cd8f625cd44 (patch) | |
tree | 899f9cf1b09a01bc073f92ab498236aed80b38ec /js/controllers/elements/element-controller.js | |
parent | 2ea8a62835f4c20efff2623306e7205e6f5bf0ba (diff) | |
parent | d220c02e246b30509b28a47fa04916ca2b8122e4 (diff) | |
download | ninja-48a2a800155fd2d608fb7191c0180cd8f625cd44.tar.gz |
Merge branch 'refs/heads/NINJAmaster' into TimelineUber
Conflicts:
js/panels/Timeline/TimelineTrack.reel/TimelineTrack.html
Signed-off-by: Jonathan Duran <jduran@motorola.com>
Diffstat (limited to 'js/controllers/elements/element-controller.js')
-rwxr-xr-x | js/controllers/elements/element-controller.js | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/js/controllers/elements/element-controller.js b/js/controllers/elements/element-controller.js index ea5fe4af..20225c61 100755 --- a/js/controllers/elements/element-controller.js +++ b/js/controllers/elements/element-controller.js | |||
@@ -15,16 +15,15 @@ exports.ElementController = Montage.create(Component, { | |||
15 | var selectedLayerIndex = this.application.ninja.timeline.getLayerIndexByID(this.application.ninja.timeline.currentLayerSelected.layerData.layerID); | 15 | var selectedLayerIndex = this.application.ninja.timeline.getLayerIndexByID(this.application.ninja.timeline.currentLayerSelected.layerData.layerID); |
16 | 16 | ||
17 | if(selectedLayerIndex === 0) { | 17 | if(selectedLayerIndex === 0) { |
18 | this.application.ninja.currentDocument.documentRoot.appendChild(el); | 18 | this.application.ninja.currentSelectedContainer.appendChild(el); |
19 | } else { | 19 | } else { |
20 | var element = this.application.ninja.timeline.arrLayers[selectedLayerIndex].layerData.elementsList[0]; | 20 | var element = this.application.ninja.timeline.arrLayers[selectedLayerIndex].layerData.elementsList[0]; |
21 | element.parentNode.insertBefore(el, element.nextSibling); | 21 | element.parentNode.insertBefore(el, element.nextSibling); |
22 | } | 22 | } |
23 | } else { | 23 | } else { |
24 | this.application.ninja.currentDocument.documentRoot.appendChild(el); | 24 | this.application.ninja.currentSelectedContainer.appendChild(el); |
25 | } | 25 | } |
26 | // Nested elements - TODO make sure the CSS is correct before nesting elements | 26 | |
27 | // this.application.ninja.currentSelectedContainer.appendChild(el); | ||
28 | if(styles) { | 27 | if(styles) { |
29 | this.application.ninja.stylesController.setElementStyles(el, styles); | 28 | this.application.ninja.stylesController.setElementStyles(el, styles); |
30 | } | 29 | } |