From e8f207dc50ad942ee8c1c1db6b146c0110ce3216 Mon Sep 17 00:00:00 2001 From: Jonathan Duran Date: Tue, 13 Mar 2012 09:15:37 -0700 Subject: Fix unassigned track element on document switch Signed-off-by: Jonathan Duran --- js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js b/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js index 18df20c2..c6b67c9c 100644 --- a/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js +++ b/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js @@ -394,6 +394,10 @@ var TimelineTrack = exports.TimelineTrack = Montage.create(Component, { draw:{ value:function () { this.ninjaStylesContoller = this.application.ninja.stylesController; + var selectedIndex = this.application.ninja.timeline.getLayerIndexByID(this.trackID); + if(this.application.ninja.timeline.arrLayers[selectedIndex].layerData.elementsList[0]){ + this.animatedElement = this.application.ninja.timeline.arrLayers[selectedIndex].layerData.elementsList[0]; + } } }, -- cgit v1.2.3