From e5830f3424c7db84f0e76b237616cbf59fe9ed1c Mon Sep 17 00:00:00 2001 From: Jonathan Duran Date: Wed, 16 May 2012 08:58:03 -0700 Subject: Remove span highlighting and start syncing pos tracks and main track keyframes Signed-off-by: Jonathan Duran --- js/panels/Timeline/PropertyTrack.reel/PropertyTrack.js | 12 ++++++++---- js/panels/Timeline/Tween.reel/Tween.js | 3 --- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/js/panels/Timeline/PropertyTrack.reel/PropertyTrack.js b/js/panels/Timeline/PropertyTrack.reel/PropertyTrack.js index 8fe87500..a8adbf04 100644 --- a/js/panels/Timeline/PropertyTrack.reel/PropertyTrack.js +++ b/js/panels/Timeline/PropertyTrack.reel/PropertyTrack.js @@ -183,16 +183,20 @@ var PropertyTrack = exports.PropertyTrack = Montage.create(Component, { }, handleClick:{ - value:function(ev){ + value:function (ev) { if (ev.shiftKey) { + if (this.trackType == "position") { + this.parentComponent.parentComponent.parentComponent.handleNewTween(ev); + } + if (this.propTweens.length < 1) { // check if there is an editor property assigned yet // get this property track's editor prop name from layer data arrays var selectIndex = this.application.ninja.timeline.getLayerIndexByID(this.trackID); - if (this.trackType === "style") { + if (this.trackType == "style") { if (this.application.ninja.timeline.arrLayers[selectIndex].layerData.arrLayerStyles[this.styleIndex].editorProperty == null) { console.log("Please enter a style property for this track before adding keyframes."); return; @@ -200,7 +204,7 @@ var PropertyTrack = exports.PropertyTrack = Montage.create(Component, { this.trackEditorProperty = this.application.ninja.timeline.arrLayers[selectIndex].layerData.arrLayerStyles[this.styleIndex].editorProperty; //console.log("Property track editorProperty set to: " + this.trackEditorProperty); } - } else if (this.trackType === "position") { + } else if (this.trackType == "position") { //console.log("Property track editorProperty set to: " + this.trackEditorProperty); } @@ -220,7 +224,7 @@ var PropertyTrack = exports.PropertyTrack = Montage.create(Component, { if (ev.offsetX > this.propTweens[this.propTweens.length - 1].tweenData.keyFramePosition) { this.insertPropTween(ev.offsetX); } else { - console.log("spitting sub keyframes not yet supported"); + console.log("Splitting style tweens not yet supported."); } } }, diff --git a/js/panels/Timeline/Tween.reel/Tween.js b/js/panels/Timeline/Tween.reel/Tween.js index bb7ce735..f857ebd4 100644 --- a/js/panels/Timeline/Tween.reel/Tween.js +++ b/js/panels/Timeline/Tween.reel/Tween.js @@ -208,9 +208,6 @@ var Tween = exports.Tween = Montage.create(Component, { } // tell track to update css rule this.parentComponent.parentComponent.updateKeyframeRule(); - - // highlight the tween's span - this.tweenspan.highlightSpan(); this.isTweenAnimated = true; } }, -- cgit v1.2.3