aboutsummaryrefslogtreecommitdiff
path: root/js/models
diff options
context:
space:
mode:
authorEric Guzman2012-07-20 11:24:19 -0700
committerEric Guzman2012-07-20 11:24:19 -0700
commit3cc29231852440508bdeec1964e40ce59f979f99 (patch)
tree2faaf3d49337437e4a84818fe24dc64a60f8c611 /js/models
parent8fdf2fc8aefee68aec4c7b5891e0375f704cbf26 (diff)
parent9053e2037821a5c8405fabb74db9635deacfe8d5 (diff)
downloadninja-3cc29231852440508bdeec1964e40ce59f979f99.tar.gz
Merge branch 'refs/heads/master' into fixes_7.1
Diffstat (limited to 'js/models')
-rwxr-xr-xjs/models/app-model.js169
-rwxr-xr-xjs/models/materials-model.js18
2 files changed, 9 insertions, 178 deletions
diff --git a/js/models/app-model.js b/js/models/app-model.js
index 1fc1ba12..1351921b 100755
--- a/js/models/app-model.js
+++ b/js/models/app-model.js
@@ -34,57 +34,6 @@ var Montage = require("montage/core/core").Montage,
34 34
35exports.AppModel = Montage.create(Component, { 35exports.AppModel = Montage.create(Component, {
36 36
37 _currentDocument: {
38 value : null
39 },
40
41 currentDocument : {
42 get : function() {
43 return this._currentDocument;
44 },
45 set : function(value) {
46 if (value === this._currentDocument) {
47 return;
48 }
49
50 if(this._currentDocument && this._currentDocument.currentView === "design") {
51 this._currentDocument.model.draw3DGrid = this.show3dGrid;
52 }
53
54 this._currentDocument = value;
55
56 if(this._currentDocument && this._currentDocument.currentView === "design") {
57 this.show3dGrid = this._currentDocument.model.draw3DGrid;
58 }
59
60 }
61 },
62
63 _livePreview: {
64 value: false
65 },
66
67 livePreview: {
68 get: function() {
69 return this._livePreview;
70 },
71 set: function(value) {
72 this._livePreview = value;
73 }
74 },
75 _chromePreview: {
76 value: false
77 },
78
79 chromePreview: {
80 get: function() {
81 return this._chromePreview;
82 },
83 set: function(value) {
84 this._chromePreview = value;
85 }
86 },
87
88 _layoutView: { 37 _layoutView: {
89 value: "layoutAll" 38 value: "layoutAll"
90 }, 39 },
@@ -98,67 +47,6 @@ exports.AppModel = Montage.create(Component, {
98 } 47 }
99 }, 48 },
100 49
101 _layoutAll: {
102 value: true
103 },
104
105 layoutAll: {
106 get: function() {
107 return this._layoutAll;
108 },
109 set: function(value) {
110
111 if(value) {
112 this.layoutView = "layoutAll";
113 this.layoutItems = false;
114 this.layoutOff = false;
115 }
116
117 this._layoutAll = value;
118
119 }
120 },
121
122 _layoutItems: {
123 value: false
124 },
125
126 layoutItems: {
127 get: function() {
128 return this._layoutItems;
129 },
130 set: function(value) {
131
132 if(value) {
133 this.layoutView = "layoutItems";
134 this.layoutAll = false;
135 this.layoutOff = false;
136 }
137
138 this._layoutItems = value;
139 }
140 },
141
142 _layoutOff: {
143 value: false
144 },
145
146 layoutOff: {
147 get: function() {
148 return this._layoutOff;
149 },
150 set: function(value) {
151
152 if(value) {
153 this.layoutView = "layoutOff";
154 this.layoutAll = false;
155 this.layoutItems = false;
156 }
157
158 this._layoutOff = value;
159 }
160 },
161
162 _snap: { 50 _snap: {
163 value: true 51 value: true
164 }, 52 },
@@ -237,63 +125,6 @@ exports.AppModel = Montage.create(Component, {
237 } 125 }
238 }, 126 },
239 127
240 _frontStageView: {
241 value: true
242 },
243
244 frontStageView: {
245 get: function() {
246 return this._frontStageView;
247 },
248 set: function(value) {
249 if(value) {
250 this.documentStageView = "front";
251 this.topStageView = false;
252 this.sideStageView = false;
253 }
254
255 this._frontStageView = value;
256 }
257 },
258
259 _topStageView: {
260 value: false
261 },
262
263 topStageView: {
264 get: function() {
265 return this._topStageView;
266 },
267 set: function(value) {
268 if(value) {
269 this.documentStageView = "top";
270 this.frontStageView = false;
271 this.sideStageView = false;
272 }
273
274 this._topStageView = value;
275 }
276 },
277
278 _sideStageView: {
279 value: false
280 },
281
282 sideStageView: {
283 get: function() {
284 return this._sideStageView;
285 },
286 set: function(value) {
287 if(value) {
288 this.documentStageView = "side";
289 this.frontStageView = false;
290 this.topStageView = false;
291 }
292
293 this._sideStageView = value;
294 }
295 },
296
297 _debug: { 128 _debug: {
298 value: true 129 value: true
299 }, 130 },
diff --git a/js/models/materials-model.js b/js/models/materials-model.js
index cc3c3fa1..ec481933 100755
--- a/js/models/materials-model.js
+++ b/js/models/materials-model.js
@@ -42,8 +42,8 @@ var RadialGradientMaterial = require("js/lib/rdge/materials/radial-gradient-mate
42var BumpMetalMaterial = require("js/lib/rdge/materials/bump-metal-material").BumpMetalMaterial; 42var BumpMetalMaterial = require("js/lib/rdge/materials/bump-metal-material").BumpMetalMaterial;
43var UberMaterial = require("js/lib/rdge/materials/uber-material").UberMaterial; 43var UberMaterial = require("js/lib/rdge/materials/uber-material").UberMaterial;
44//var CloudMaterial = require("js/lib/rdge/materials/cloud-material").CloudMaterial; 44//var CloudMaterial = require("js/lib/rdge/materials/cloud-material").CloudMaterial;
45//var RadialBlurMaterial = require("js/lib/rdge/materials/radial-blur-material").RadialBlurMaterial; 45var RadialBlurMaterial = require("js/lib/rdge/materials/radial-blur-material").RadialBlurMaterial;
46//var RaidersMaterial = require("js/lib/rdge/materials/radial-blur-material").RaidersMaterial; 46var DarkBlurMaterial = require("js/lib/rdge/materials/radial-blur-material").DarkBlurMaterial;
47var PlasmaMaterial = require("js/lib/rdge/materials/plasma-material").PlasmaMaterial; 47var PlasmaMaterial = require("js/lib/rdge/materials/plasma-material").PlasmaMaterial;
48var PulseMaterial = require("js/lib/rdge/materials/pulse-material").PulseMaterial; 48var PulseMaterial = require("js/lib/rdge/materials/pulse-material").PulseMaterial;
49//var TunnelMaterial = require("js/lib/rdge/materials/tunnel-material").TunnelMaterial; 49//var TunnelMaterial = require("js/lib/rdge/materials/tunnel-material").TunnelMaterial;
@@ -52,7 +52,7 @@ var FlagMaterial = require("js/lib/rdge/materials/flag-material").FlagMaterial;
52//var SquareTunnelMaterial = require("js/lib/rdge/materials/square-tunnel-material").SquareTunnelMaterial; 52//var SquareTunnelMaterial = require("js/lib/rdge/materials/square-tunnel-material").SquareTunnelMaterial;
53//var FlyMaterial = require("js/lib/rdge/materials/fly-material").FlyMaterial; 53//var FlyMaterial = require("js/lib/rdge/materials/fly-material").FlyMaterial;
54var WaterMaterial = require("js/lib/rdge/materials/water-material").WaterMaterial; 54var WaterMaterial = require("js/lib/rdge/materials/water-material").WaterMaterial;
55var ParisMaterial = require("js/lib/rdge/materials/water-material").ParisMaterial; 55var BlueSkyMaterial = require("js/lib/rdge/materials/water-material").BlueSkyMaterial;
56//var ZInvertMaterial = require("js/lib/rdge/materials/z-invert-material").ZInvertMaterial; 56//var ZInvertMaterial = require("js/lib/rdge/materials/z-invert-material").ZInvertMaterial;
57//var DeformMaterial = require("js/lib/rdge/materials/deform-material").DeformMaterial; 57//var DeformMaterial = require("js/lib/rdge/materials/deform-material").DeformMaterial;
58//var StarMaterial = require("js/lib/rdge/materials/star-material").StarMaterial; 58//var StarMaterial = require("js/lib/rdge/materials/star-material").StarMaterial;
@@ -74,8 +74,10 @@ exports.MaterialsModel = Montage.create(Component, {
74 value: function() { 74 value: function() {
75 // Load all the materials 75 // Load all the materials
76 this.addMaterial(new FlatMaterial()); 76 this.addMaterial(new FlatMaterial());
77 this.addMaterial(new BlueSkyMaterial());
77 this.addMaterial(new BumpMetalMaterial()); 78 this.addMaterial(new BumpMetalMaterial());
78 //this.addMaterial(new CloudMaterial()); 79 //this.addMaterial(new CloudMaterial());
80 this.addMaterial(new DarkBlurMaterial());
79 //this.addMaterial(new DeformMaterial()); 81 //this.addMaterial(new DeformMaterial());
80 this.addMaterial(new FlagMaterial()); 82 this.addMaterial(new FlagMaterial());
81 //this.addMaterial(new FlyMaterial()); 83 //this.addMaterial(new FlyMaterial());
@@ -83,12 +85,10 @@ exports.MaterialsModel = Montage.create(Component, {
83 //this.addMaterial(new KeleidoscopeMaterial()); 85 //this.addMaterial(new KeleidoscopeMaterial());
84 this.addMaterial(new LinearGradientMaterial()); 86