aboutsummaryrefslogtreecommitdiff
path: root/js/stage/stage.reel
diff options
context:
space:
mode:
authorValerio Virgillito2012-05-16 11:23:12 -0700
committerValerio Virgillito2012-05-16 11:23:12 -0700
commit0ebb822b0535bf1bb100b3f3cb396c8b6d3383f1 (patch)
tree4171cda275fa5b632c2cdc33ee762128fd84be8f /js/stage/stage.reel
parentb2c8041058ab8d16ca49d70ed24ddd29e79f51d2 (diff)
downloadninja-0ebb822b0535bf1bb100b3f3cb396c8b6d3383f1.tar.gz
fixing some of the document bindings.
Signed-off-by: Valerio Virgillito <valerio@motorola.com>
Diffstat (limited to 'js/stage/stage.reel')
-rwxr-xr-xjs/stage/stage.reel/stage.html3
-rwxr-xr-xjs/stage/stage.reel/stage.js23
2 files changed, 26 insertions, 0 deletions
diff --git a/js/stage/stage.reel/stage.html b/js/stage/stage.reel/stage.html
index 30c3d231..88cd6149 100755
--- a/js/stage/stage.reel/stage.html
+++ b/js/stage/stage.reel/stage.html
@@ -22,6 +22,9 @@
22 "prototype": "js/stage/stage-deps", 22 "prototype": "js/stage/stage-deps",
23 "properties": { 23 "properties": {
24 "stage": {"@": "owner"} 24 "stage": {"@": "owner"}
25 },
26 "bindings": {
27 "currentDocument": {"<-": "@owner.activeDocument"}
25 } 28 }
26 }, 29 },
27 30
diff --git a/js/stage/stage.reel/stage.js b/js/stage/stage.reel/stage.js
index deed4112..125155d8 100755
--- a/js/stage/stage.reel/stage.js
+++ b/js/stage/stage.reel/stage.js
@@ -164,6 +164,29 @@ exports.Stage = Montage.create(Component, {
164 set: function(value) { this._userContentBorder = value; } 164 set: function(value) { this._userContentBorder = value; }
165 }, 165 },
166 166
167 _activeDocument : {
168 value : null,
169 enumerable : false
170 },
171
172 activeDocument : {
173 get : function() {
174 return this._activeDocument;
175 },
176 set : function(document) {
177 ///// If the document is null set default stylesheets to null
178
179 if(!document) {
180 return false;
181 }
182
183 ///// setting document via binding
184 this._activeDocument = document;
185
186 },
187 enumerable : false
188 },
189
167 willDraw: { 190 willDraw: {
168 value: function() { 191 value: function() {
169 if(this.resizeCanvases) { 192 if(this.resizeCanvases) {