aboutsummaryrefslogtreecommitdiff
path: root/js/panels/properties/content.reel
diff options
context:
space:
mode:
authorJose Antonio Marquez2012-02-15 20:37:48 -0800
committerJose Antonio Marquez2012-02-15 20:37:48 -0800
commit89b5e793ea88ef235b54b6e1d1c379698d3e612b (patch)
tree4d29118f35df77ca6b423119a4ff61694a442cbf /js/panels/properties/content.reel
parent9d2c2a80483415d7560b00cda5519153db23e241 (diff)
parentd366c0bd1af6471511217ed574083e15059519b5 (diff)
downloadninja-89b5e793ea88ef235b54b6e1d1c379698d3e612b.tar.gz
Merge branch 'refs/heads/NinjaInternal' into Color
Diffstat (limited to 'js/panels/properties/content.reel')
-rwxr-xr-x[-rw-r--r--]js/panels/properties/content.reel/content.css0
-rwxr-xr-x[-rw-r--r--]js/panels/properties/content.reel/content.html0
-rwxr-xr-x[-rw-r--r--]js/panels/properties/content.reel/content.js38
3 files changed, 38 insertions, 0 deletions
diff --git a/js/panels/properties/content.reel/content.css b/js/panels/properties/content.reel/content.css
index 2537aea2..2537aea2 100644..100755
--- a/js/panels/properties/content.reel/content.css
+++ b/js/panels/properties/content.reel/content.css
diff --git a/js/panels/properties/content.reel/content.html b/js/panels/properties/content.reel/content.html
index ab485323..ab485323 100644..100755
--- a/js/panels/properties/content.reel/content.html
+++ b/js/panels/properties/content.reel/content.html
diff --git a/js/panels/properties/content.reel/content.js b/js/panels/properties/content.reel/content.js
index 0088447a..53926c78 100644..100755
--- a/js/panels/properties/content.reel/content.js
+++ b/js/panels/properties/content.reel/content.js
@@ -54,8 +54,17 @@ exports.Content = Montage.create(Component, {
54 this.eventManager.addEventListener( "elementChanging", this, false); 54 this.eventManager.addEventListener( "elementChanging", this, false);
55 } 55 }
56 56
57 this.eventManager.addEventListener("openDocument", this, false);
58 }
59 },
60
61 // Document is opened - Display the current selection
62 handleOpenDocument: {
63 value: function() {
64
57 this.eventManager.addEventListener( "elementChange", this, false); 65 this.eventManager.addEventListener( "elementChange", this, false);
58 66
67 // For now always assume that the stage is selected by default
59 if(this.application.ninja.selectedElements.length === 0) { 68 if(this.application.ninja.selectedElements.length === 0) {
60 this.displayStageProperties(); 69 this.displayStageProperties();
61 } 70 }
@@ -150,6 +159,35 @@ exports.Content = Montage.create(Component, {
150 this.customPi = stage.elementModel.pi; 159 this.customPi = stage.elementModel.pi;
151 this.displayCustomProperties(stage, stage.elementModel.pi); 160 this.displayCustomProperties(stage, stage.elementModel.pi);
152 } 161 }
162
163 // For now hardcode the background since it is the only custom property
164 // No need to loop through all the properties.
165 var backgroundChip = this.customSections[0].content.controls["background"];
166 backgroundChip.initialColor = ElementsMediator.getProperty(stage, "background");
167
168 /*
169 var customPI = PiData[this.customPi];
170 // Get all the custom section for the custom PI
171 for(var i = 0, customSec; customSec = customPI[i]; i++) {
172
173 // Now set the Fields for the custom PI
174 for(var j = 0, fields; fields = customSec.Section[j]; j++) {
175 for(var k = 0, control; control = fields[k]; k++) {
176
177 var colorChipEl = this.customSections[i].content.controls[control.id];
178 this.foo = colorChipEl;
179 colorChipEl.addEventListener("firstDraw", this, false);
180
181 }
182 }
183 }
184 */
185 }
186 },
187
188 handleFirstDraw: {
189 value: function() {
190 this.foo.chipBtn.color('rgb', {wasSetByCode: true, type: 'change', color: {r: 255, g: 0, b: 0}, css: 'rgb(255,0,0)'});
153 } 191 }
154 }, 192 },
155 193