diff options
author | Nivesh Rajbhandari | 2012-05-04 14:42:00 -0700 |
---|---|---|
committer | Nivesh Rajbhandari | 2012-05-04 14:42:00 -0700 |
commit | 8f8f7f9a36fb9abadea2a9f25aef0084946bebc9 (patch) | |
tree | f6c756f20b302415ac3dae5ea2e1f5788b7bfe94 /js/controllers | |
parent | 8f1385d4aa12173fb4d9af695b8e5036f675b621 (diff) | |
download | ninja-8f8f7f9a36fb9abadea2a9f25aef0084946bebc9.tar.gz |
Removed special-casing for new template workflow. Instead, we will enforce a width and height on the body in order to do 3d.
Signed-off-by: Nivesh Rajbhandari <mqg734@motorola.com>
Diffstat (limited to 'js/controllers')
-rwxr-xr-x | js/controllers/elements/body-controller.js | 28 |
1 files changed, 28 insertions, 0 deletions
diff --git a/js/controllers/elements/body-controller.js b/js/controllers/elements/body-controller.js index 14aeae24..943594f2 100755 --- a/js/controllers/elements/body-controller.js +++ b/js/controllers/elements/body-controller.js | |||
@@ -28,11 +28,39 @@ exports.BodyController = Montage.create(ElementController, { | |||
28 | 28 | ||
29 | getProperty: { | 29 | getProperty: { |
30 | value: function(el, p) { | 30 | value: function(el, p) { |
31 | switch(p) { | ||
32 | case "background" : | ||
33 | return this.application.ninja.colorController.getColorObjFromCss(this.application.ninja.stylesController.getElementStyle(el, "background-color", true, true)); | ||
34 | case "border": | ||
35 | return 0; | ||
36 | case "height": | ||
37 | case "width": | ||
38 | case "-webkit-transform-style": | ||
39 | return this.application.ninja.stylesController.getElementStyle(el, p, true, true); | ||
40 | default: | ||
41 | return ElementController.getProperty(el, p, true, true); | ||
42 | //console.log("Undefined Stage property ", p); | ||
43 | } | ||
31 | } | 44 | } |
32 | }, | 45 | }, |
33 | 46 | ||
34 | setProperty: { | 47 | setProperty: { |
35 | value: function(el, p, value) { | 48 | value: function(el, p, value) { |
49 | switch(p) { | ||
50 | case "body-background": | ||
51 | case "background": | ||
52 | this.application.ninja.stylesController.setElementStyle(el, "background-color", value, true); | ||
53 | break; | ||
54 | case "overflow": | ||
55 | case "width": | ||
56 | case "height": | ||
57 | case "-webkit-transform-style": | ||
58 | this.application.ninja.stylesController.setElementStyle(el, p, value, true); | ||
59 | this.application.ninja.stage.updatedStage = true; | ||
60 | break; | ||
61 | default: | ||
62 | console.log("Undefined property ", p, "for the Body Controller"); | ||
63 | } | ||
36 | } | 64 | } |
37 | }, | 65 | }, |
38 | 66 | ||