aboutsummaryrefslogtreecommitdiff
path: root/js/io/ui/new-file-dialog/new-file-workflow-model.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/io/ui/new-file-dialog/new-file-workflow-model.js')
-rwxr-xr-xjs/io/ui/new-file-dialog/new-file-workflow-model.js49
1 files changed, 49 insertions, 0 deletions
diff --git a/js/io/ui/new-file-dialog/new-file-workflow-model.js b/js/io/ui/new-file-dialog/new-file-workflow-model.js
new file mode 100755
index 00000000..892dd3cf
--- /dev/null
+++ b/js/io/ui/new-file-dialog/new-file-workflow-model.js
@@ -0,0 +1,49 @@
1/* <copyright>
2This file contains proprietary software owned by Motorola Mobility, Inc.<br/>
3No 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.
5</copyright> */
6
7
8//a singleton
9
10exports.NewFileWorkflowModel = Object.create(Object.prototype, {
11 prepareContents: {
12 value: function(id){
13 var contents = [];
14 if(!!this.projectTypeData[id].children && (this.projectTypeData[id].children.length > 0)){
15 this.projectTypeData[id].children.forEach(function(elem){
16 if(!!this.projectTypeData[elem]){
17 contents.push(this.projectTypeData[elem]);
18 }
19 }, this);
20 }
21
22 return contents;
23 }
24 },
25
26 defaultProjectType:{
27 writable: true,
28 enumerable: true,
29 value: null
30 },
31
32 callback : {
33 enumerable: true,
34 writable: true,
35 value: null
36 },
37
38 callbackScope : {
39 enumerable: true,
40 writable: true,
41 value: null
42 },
43
44 projectTypeData:{
45 writable:true,
46 enumerable:false,
47 value:{}
48 }
49});