aboutsummaryrefslogtreecommitdiff
path: root/js/panels/Timeline/Tween.reel
diff options
context:
space:
mode:
Diffstat (limited to 'js/panels/Timeline/Tween.reel')
-rw-r--r--js/panels/Timeline/Tween.reel/Tween.js24
1 files changed, 11 insertions, 13 deletions
diff --git a/js/panels/Timeline/Tween.reel/Tween.js b/js/panels/Timeline/Tween.reel/Tween.js
index c21b5f91..48b41023 100644
--- a/js/panels/Timeline/Tween.reel/Tween.js
+++ b/js/panels/Timeline/Tween.reel/Tween.js
@@ -216,12 +216,6 @@ var Tween = exports.Tween = Montage.create(Component, {
216 this.tweenedProperties["height"] = this.parentComponent.parentComponent.animatedElement.offsetHeight; 216 this.tweenedProperties["height"] = this.parentComponent.parentComponent.animatedElement.offsetHeight;
217 } 217 }
218 218
219 // skewX
220
221 // skewY
222
223 // rotation
224
225 // tell track to update css rule 219 // tell track to update css rule
226 this.parentComponent.parentComponent.updateKeyframeRule(); 220 this.parentComponent.parentComponent.updateKeyframeRule();
227 221
@@ -246,7 +240,7 @@ var Tween = exports.Tween = Montage.create(Component, {
246 var selectIndex = this.application.ninja.timeline.getLayerIndexByID(this.parentComponent.parentComponent.trackID); 240 var selectIndex = this.application.ninja.timeline.getLayerIndexByID(this.parentComponent.parentComponent.trackID);
247 this.application.ninja.timeline.selectLayer(selectIndex, true); 241 this.application.ninja.timeline.selectLayer(selectIndex, true);
248 242
249 // tell timeline to deselect all other tweens and push this one as the currentSelectedTweens in timeline 243 // tell timeline to deselect all other tweens and push this one into the selectedTweens in timeline
250 this.application.ninja.timeline.deselectTweens(); 244 this.application.ninja.timeline.deselectTweens();
251 this.application.ninja.timeline.selectedTweens.push(this); 245 this.application.ninja.timeline.selectedTweens.push(this);
252 246
@@ -257,13 +251,17 @@ var Tween = exports.Tween = Montage.create(Component, {
257 var currentMillisec = currentMillisecPerPixel * this.keyFramePosition; 251 var currentMillisec = currentMillisecPerPixel * this.keyFramePosition;
258 this.application.ninja.timeline.updateTimeText(currentMillisec); 252 this.application.ninja.timeline.updateTimeText(currentMillisec);
259 253
260 // move animated element to correct position on stage 254 if(this.parentComponent.parentComponent.isSubproperty){
261 var currentTop = this.tweenedProperties["top"] + "px"; 255 console.log("sub prop tween selection");
262 var currentLeft = this.tweenedProperties["left"] + "px"; 256 // set property specific style on element
263 257 } else {
264 this.application.ninja.elementMediator.setProperty([this.parentComponent.parentComponent.animatedElement], "top", [currentTop], "Change", "tween"); 258 // move animated element to correct position on stage
265 this.application.ninja.elementMediator.setProperty([this.parentComponent.parentComponent.animatedElement], "left", [currentLeft], "Change", "tween"); 259 var currentTop = this.tweenedProperties["top"] + "px";
260 var currentLeft = this.tweenedProperties["left"] + "px";
266 261
262 this.application.ninja.elementMediator.setProperty([this.parentComponent.parentComponent.animatedElement], "top", [currentTop], "Change", "tween");
263 this.application.ninja.elementMediator.setProperty([this.parentComponent.parentComponent.animatedElement], "left", [currentLeft], "Change", "tween");
264 }
267 } 265 }
268 }, 266 },
269 267