aboutsummaryrefslogtreecommitdiff
path: root/js/panels
diff options
context:
space:
mode:
Diffstat (limited to 'js/panels')
-rw-r--r--js/panels/Timeline/Layer.reel/Layer.js2709
1 files changed, 1338 insertions, 1371 deletions
diff --git a/js/panels/Timeline/Layer.reel/Layer.js b/js/panels/Timeline/Layer.reel/Layer.js
index 4dd9e88a..f7b66a39 100644
--- a/js/panels/Timeline/Layer.reel/Layer.js
+++ b/js/panels/Timeline/Layer.reel/Layer.js
@@ -1,1372 +1,1339 @@
1/* <copyright> 1/* <copyright>
2 This file contains proprietary software owned by Motorola Mobility, Inc.<br/> 2 This file contains proprietary software owned by Motorola Mobility, Inc.<br/>
3 No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/> 3 No rights, expressed or implied, whatsoever to this software are provided by Motorola Mobility, Inc. hereunder.<br/>
4 (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved. 4 (c) Copyright 2011 Motorola Mobility, Inc. All Rights Reserved.
5 </copyright> */ 5 </copyright> */
6 6
7var Montage = require("montage/core/core").Montage; 7var Montage = require("montage/core/core").Montage;
8var Component = require("montage/ui/component").Component; 8var Component = require("montage/ui/component").Component;
9var Collapser = require("js/panels/Timeline/Collapser").Collapser; 9var Hintable = require("js/components/hintable.reel").Hintable;
10var Hintable = require("js/components/hintable.reel").Hintable; 10var nj = require("js/lib/NJUtils").NJUtils;
11var LayerStyle = require("js/panels/Timeline/Style.reel").LayerStyle; 11var ElementsMediator = require("js/mediators/element-mediator").ElementMediator;
12var DynamicText = require("montage/ui/dynamic-text.reel").DynamicText; 12
13var defaultEventManager = require("montage/core/event/event-manager").defaultEventManager; 13var Layer = exports.Layer = Montage.create(Component, {
14var nj = require("js/lib/NJUtils").NJUtils; 14
15var ElementsMediator = require("js/mediators/element-mediator").ElementMediator; 15 /* Begin: Models */
16 16
17var Layer = exports.Layer = Montage.create(Component, { 17 _dynamicLayerTag: {
18 18 value: null
19 dynamicLayerTag: { 19 },
20 value: null, 20 dynamicLayerTag: {
21 serializable: true 21 serializable: true,
22 }, 22 get: function() {
23 23 return this._dynamicLayerTag;
24 positionCollapser: { 24 },
25 value: null, 25 set: function(newVal) {
26 serializable: true 26 this._dynamicLayerTag = newVal;
27 }, 27 }
28 28 },
29 transformCollapser: { 29
30 value: null, 30 _positionCollapser: {
31 serializable: true 31 value: null
32 }, 32 },
33 33 positionCollapser: {
34 styleCollapser: { 34 serializable: true,
35 value: null, 35 get: function() {
36 serializable: true 36 return this._positionCollapser;
37 }, 37 },
38 38 set: function(newVal) {
39 clickerMain: { 39 this._positionCollapser = newVal;
40 value: null, 40 }
41 serializable: true 41 },
42 }, 42
43 43 _transformCollapser: {
44 myLabel: { 44 value: null
45 value: null, 45 },
46 serializable: true 46 transformCollapser: {
47 }, 47 serializable: true,
48 48 get: function() {
49 /* Begin: Models */ 49 return this._transformCollapser;
50 50 },
51 /* Main collapser model: the main collapser for the layer */ 51 set: function(newVal) {
52 _mainCollapser : { 52 this._transformCollapser = newVal;
53 value: false 53 }
54 }, 54 },
55 mainCollapser: { 55
56 get: function() { 56 _styleCollapser: {
57 return this._mainCollapser; 57 value: null
58 }, 58 },
59 set: function(newVal) { 59 styleCollapser: {
60 this._mainCollapser = newVal; 60 serializable: true,
61 }, 61 get: function() {
62 serializable: true 62 return this._styleCollapser;
63 }, 63 },
64 64 set: function(newVal) {
65 /* Style models: the array of styles, and the repetition that uses them */ 65 this._styleCollapser = newVal;
66 _arrLayerStyles : { 66 }
67 value: [] 67 },
68 }, 68
69 arrLayerStyles : { 69 _clickerMain: {
70 serializable: true, 70 value: null
71 get: function() { 71 },
72 return this._arrLayerStyles; 72 clickerMain: {
73 }, 73 serializable: true,
74 set: function(newVal) { 74 get: function() {
75 this._arrLayerStyles = newVal; 75 return this._clickerMain;
76 } 76 },
77 }, 77 set: function(newVal) {
78 _styleRepetition : { 78 this._clickerMain = newVal;
79 value: false 79 }
80 }, 80 },
81 styleRepetition : { 81
82 serializable: true, 82 _myLabel: {
83 get: function() { 83 value: null
84 return this._styleRepetition; 84 },
85 }, 85 myLabel: {
86 set: function(newVal) { 86 serializable: true,
87 this._styleRepetition = newVal; 87 get: function() {
88 } 88 return this._myLabel;
89 }, 89 },
90 _styleCounter : { 90 set: function(newVal) {
91 value: 0 91 this._myLabel = newVal;
92 }, 92 }
93 styleCounter:{ 93 },
94 serializable:true, 94
95 get:function () { 95 _mainCollapser : {
96 return this._styleCounter; 96 value: false
97 }, 97 },
98 set:function (newVal) { 98 mainCollapser: {
99 this._styleCounter = newVal; 99 get: function() {
100 } 100 return this._mainCollapser;
101 }, 101 },
102 _selectedStyleIndex: { 102 set: function(newVal) {
103 value: false 103 this._mainCollapser = newVal;
104 }, 104 },
105 selectedStyleIndex: { 105 serializable: true
106 get: function() { 106 },
107 return this._selectedStyleIndex; 107
108 }, 108 _arrLayerStyles : {
109 set: function(newVal) { 109 value: []
110 if (typeof(newVal) === "undefined") { 110 },
111 return; 111 arrLayerStyles : {
112 } 112 serializable: true,
113 if (newVal !== this._selectedStyleIndex) { 113 get: function() {
114 this._selectedStyleIndex = newVal; 114 return this._arrLayerStyles;
115 this.layerData.selectedStyleIndex = newVal; 115 },
116 } 116 set: function(newVal) {
117 } 117 this._arrLayerStyles = newVal;
118 }, 118 }
119 _storedStyleIndex : { 119 },
120 value: false 120
121 }, 121 _styleRepetition : {
122 122 value: false
123 /* Layer models: the name, ID, and selected and animation booleans for the layer */ 123 },
124 _layerName:{ 124 styleRepetition : {
125 value: "" 125 serializable: true,
126 }, 126 get: function() {
127 127 return this._styleRepetition;
128 layerName:{ 128 },
129 serializable: true, 129 set: function(newVal) {
130 get:function(){ 130 this._styleRepetition = newVal;
131 return this._layerName; 131 }
132 }, 132 },
133 set:function(newVal){ 133
134 if (this._layerEditable.value !== newVal) { 134 _styleCounter : {
135 this._layerEditable.value = newVal; 135 value: 0
136 } 136 },
137 if (this._layerName !== newVal) { 137 styleCounter:{
138 this._layerName = newVal; 138 serializable:true,
139 } 139 get:function () {
140 if (this.layerData.layerName !== newVal) { 140 return this._styleCounter;
141 this.layerData.layerName = newVal; 141 },
142 } 142 set:function (newVal) {
143 143 this._styleCounter = newVal;
144 if (typeof(this.dynamicLayerName) !== "undefined") { 144 }
145 if (this.dynamicLayerName.value !== newVal) { 145 },
146 this.dynamicLayerName.value = newVal; 146
147 } 147 _selectedStyleIndex: {
148 } 148 value: false
149 this.needsDraw = true; 149 },
150 } 150 selectedStyleIndex: {
151 }, 151 get: function() {
152 _layerID:{ 152 return this._selectedStyleIndex;
153 value: "Default Layer ID" 153 },