aboutsummaryrefslogtreecommitdiff
path: root/js/panels/Timeline/Layer.reel/Layer.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/panels/Timeline/Layer.reel/Layer.js')
-rw-r--r--js/panels/Timeline/Layer.reel/Layer.js19
1 files changed, 15 insertions, 4 deletions
diff --git a/js/panels/Timeline/Layer.reel/Layer.js b/js/panels/Timeline/Layer.reel/Layer.js
index b41680be..069d3c4b 100644
--- a/js/panels/Timeline/Layer.reel/Layer.js
+++ b/js/panels/Timeline/Layer.reel/Layer.js
@@ -255,12 +255,11 @@ var Layer = exports.Layer = Montage.create(Component, {
255 if (value !== this._isSelected) { 255 if (value !== this._isSelected) {
256 // Only concerned about different values 256 // Only concerned about different values
257 if (value === false) { 257 if (value === false) {
258 // If changing from false to true, we need to deselect any associated styles 258 // If changing from true to false, we need to deselect any associated styles
259 this.selectStyle(false); 259 this.selectStyle(false);
260 } 260 }
261 this._isSelected = value; 261 this._isSelected = value;
262 this.layerData.isSelected = value; 262 this.layerData.isSelected = value;
263 //this.needsDraw = true;
264 } 263 }
265 264
266 } 265 }
@@ -381,7 +380,6 @@ var Layer = exports.Layer = Montage.create(Component, {
381 return this._bypassAnimation; 380 return this._bypassAnimation;
382 }, 381 },
383 set: function(newVal) { 382 set: function(newVal) {
384 //console.log("layer.js _bypassAnimation setter " + newVal)
385 this._bypassAnimation = newVal; 383 this._bypassAnimation = newVal;
386 } 384 }
387 }, 385 },
@@ -406,7 +404,6 @@ var Layer = exports.Layer = Montage.create(Component, {
406 404
407 setData:{ 405 setData:{
408 value:function(){ 406 value:function(){
409 this.log('layer: setData called')
410 this.layerName = this.layerData.layerName; 407 this.layerName = this.layerData.layerName;
411 this.layerID = this.layerData.layerID; 408 this.layerID = this.layerData.layerID;
412 this.arrLayerStyles = this.layerData.arrLayerStyles; 409 this.arrLayerStyles = this.layerData.arrLayerStyles;
@@ -424,9 +421,13 @@ var Layer = exports.Layer = Montage.create(Component, {
424 this.dtextScaleX = this.layerData.dtextScaleX; 421 this.dtextScaleX = this.layerData.dtextScaleX;
425 this.dtextScaleY = this.layerData.dtextScaleY; 422 this.dtextScaleY = this.layerData.dtextScaleY;
426 this.dtextRotate = this.layerData.dtextRotate; 423 this.dtextRotate = this.layerData.dtextRotate;
424 this._isFirstDraw = this.layerData._isFirstDraw;
427 this.needsDraw = true; 425 this.needsDraw = true;
428 } 426 }
429 }, 427 },
428 _isFirstDraw : {
429 value: true
430 },
430 431
431 /* END: Models */ 432 /* END: Models */
432 433
@@ -483,6 +484,16 @@ var Layer = exports.Layer = Montage.create(Component, {
483 } 484 }
484 } 485 }
485 }, 486 },
487 didDraw: {
488 value: function() {
489 if ((this.isSelected === true) && (this._isFirstDraw === true)) {
490 // Once we're done drawing the first time we need to tell the TimelinePanel if
491 // this layer is supposed to be selected.
492 this.parentComponent.parentComponent.selectedLayerID = this.layerID;
493 this._isFirstDraw = false;
494 }
495 }
496 },
486 /* End: Draw cycle */ 497 /* End: Draw cycle */
487 498
488 /* Begin: Controllers */ 499 /* Begin: Controllers */