From d3e2e8c0e4be6a324eac3a3ea050b4c41183f79b Mon Sep 17 00:00:00 2001 From: Jon Reid Date: Thu, 17 May 2012 17:16:11 -0700 Subject: Timeline: Bug fixes for multiselect --- js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js | 9 ++++++++- js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js index 1ddb3977..ce8174b0 100644 --- a/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js +++ b/js/panels/Timeline/TimelinePanel.reel/TimelinePanel.js @@ -1200,7 +1200,6 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { // Select the layers, or clear the selection if none were found if (arrSelectedElements.length > 0) { - console.log("TimelinePanel.updateStageSelection, ", arrSelectedElements) this.application.ninja.selectionController.selectElements(arrSelectedElements); } else { this.application.ninja.selectionController.executeSelectElement(); @@ -1641,6 +1640,13 @@ var TimelinePanel = exports.TimelinePanel = Montage.create(Component, { selectLayer:{ value:function (layerIndex, userSelection) { + console.log("=----> Please update your component to use the new TimelinePanel.selectLayers method. <----="); + this.selectLayers([layerIndex]); + if (userSelection === true) { + this.updateStageSelection(); + } + + /* console.log('TimelinePanel.selectLayer') @@ -1676,6 +1682,7 @@ console.log('TimelinePanel.selectLayer') this._captureSelection = true; } this.resetMasterDuration(); + */ } }, diff --git a/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js b/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js index 0e430000..e4e90d51 100644 --- a/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js +++ b/js/panels/Timeline/TimelineTrack.reel/TimelineTrack.js @@ -644,7 +644,7 @@ var TimelineTrack = exports.TimelineTrack = Montage.create(Component, { newTween.tweenData = {}; if (clickPos == 0) { - this.animatedElement = this.application.ninja.timeline.currentLayerSelected.layerData.stageElement; + this.animatedElement = this.application.ninja.timeline.arrLayers[this.application.ninja.timeline.currentLayersSelected[0]].layerData.stageElement; newTween.tweenData.spanWidth = 0; newTween.tweenData.keyFramePosition = 0; newTween.tweenData.keyFrameMillisec = 0; -- cgit v1.2.3