From fb8aacbadba8dffb9619eb16e4626c197dc9264d Mon Sep 17 00:00:00 2001 From: Jonathan Duran Date: Mon, 27 Feb 2012 10:23:05 -0800 Subject: Timeline : Selection Fix Signed-off-by: Kruti Shah Signed-off-by: Jonathan Duran --- js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) (limited to 'js/panels/Timeline') diff --git a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js index 2143dafd..797a7cbf 100644 --- a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js +++ b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js @@ -230,8 +230,6 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { { this._openDoc=true; NJevent('newLayer',{key:this._hashKey,ele:this.application.ninja.currentDocument.documentRoot.children[myIndex]}) -// this.selectLayer(myIndex); -// TimelineTrack.retrieveStoredTweens(); myIndex++; } }else{ @@ -488,7 +486,6 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { if(this._openDoc){ event.detail.ele.uuid =nj.generateRandom(); thingToPush.elementsList.push(event.detail.ele); - this._openDoc=false; } newTrack.trackID = this.currentLayerNumber; @@ -534,6 +531,11 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { this.selectLayer(0); } + + if(this._openDoc){ + this.hashElementMapToLayer.setItem(event.detail.ele.uuid, event.detail.ele,this.currentLayerSelected); + this._openDoc=false; + } this._LayerUndoObject = thingToPush; this._LayerUndoIndex = thingToPush.layerID; this._LayerUndoStatus = true; @@ -733,6 +735,7 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { } } hashLayerObject[key][index] = value; + console.log(hashLayerObject) this.counter = 0; } }, @@ -827,6 +830,7 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { } this.mappingArray[key]["ele"] = value; this.mappingArray[key].layerID = layer.layerID; + console.log(this.mappingArray) } }, @@ -863,6 +867,10 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { this.trackRepetition.selectedIndexes = [layerIndex]; this.currentLayerSelected = this.arrLayers[layerIndex]; this.currentTrackSelected = this.arrTracks[layerIndex]; + if(this._captureSelection){ + this.application.ninja.selectionController.selectElements(this.currentLayerSelected.elementsList) + } + this._captureSelection = true; } else { this.layerRepetition.selectedIndexes = null; this.trackRepetition.selectedIndexes = null; -- cgit v1.2.3