diff options
author | Armen Kesablyan | 2012-06-06 14:42:12 -0700 |
---|---|---|
committer | Armen Kesablyan | 2012-06-06 14:42:12 -0700 |
commit | 557473639c1854d2e545f542d5f8656a040d575c (patch) | |
tree | e9e5b975d5e514e53388111e2bdd8719208adaa6 /js | |
parent | 5ecbbe908a5527dc42d461c8ddfd33b4c7e0ba4f (diff) | |
download | ninja-557473639c1854d2e545f542d5f8656a040d575c.tar.gz |
Object Controller
Signed-off-by: Armen Kesablyan <armen@motorola.com>
Diffstat (limited to 'js')
-rw-r--r-- | js/controllers/objects-controller.js | 24 | ||||
-rwxr-xr-x | js/stage/binding-view.reel/binding-view.js | 1 |
2 files changed, 15 insertions, 10 deletions
diff --git a/js/controllers/objects-controller.js b/js/controllers/objects-controller.js index 32f24d5c..6da53b0f 100644 --- a/js/controllers/objects-controller.js +++ b/js/controllers/objects-controller.js | |||
@@ -94,15 +94,15 @@ var objectsController = exports.ObjectsController = Montage.create(Component, { | |||
94 | if(descriptors.hasOwnProperty(property)) { | 94 | if(descriptors.hasOwnProperty(property)) { |
95 | descriptor = descriptors[property]; | 95 | descriptor = descriptors[property]; |
96 | 96 | ||
97 | bindingArgsObject = { | 97 | bindingArgsObject = { |
98 | sourceObject : object, | 98 | sourceObject : object, |
99 | sourceObjectPropertyPath : property, | 99 | sourceObjectPropertyPath : property, |
100 | boundObject : descriptor.boundObject, | 100 | boundObject : descriptor.boundObject, |
101 | boundObjectPropertyPath : descriptor.boundObjectPropertyPath, | 101 | boundObjectPropertyPath : descriptor.boundObjectPropertyPath, |
102 | oneway : descriptor.oneway | 102 | oneway : descriptor.oneway |
103 | }; | 103 | }; |
104 | 104 | ||
105 | bindingsArray.push(bindingArgsObject); | 105 | bindingsArray.push(bindingArgsObject); |
106 | } | 106 | } |
107 | } | 107 | } |
108 | } | 108 | } |
@@ -125,6 +125,7 @@ var objectsController = exports.ObjectsController = Montage.create(Component, { | |||
125 | } | 125 | } |
126 | 126 | ||
127 | return prototypes.map(function(proto) { | 127 | return prototypes.map(function(proto) { |
128 | |||
128 | var metadata = proto._montage_metadata, | 129 | var metadata = proto._montage_metadata, |
129 | objectName = (metadata) ? metadata.objectName : "Object"; | 130 | objectName = (metadata) ? metadata.objectName : "Object"; |
130 | 131 | ||
@@ -142,8 +143,11 @@ var objectsController = exports.ObjectsController = Montage.create(Component, { | |||
142 | var properties = []; | 143 | var properties = []; |
143 | 144 | ||
144 | for(var key in object) { | 145 | for(var key in object) { |
146 | debugger; | ||
145 | if(object.hasOwnProperty(key)) { | 147 | if(object.hasOwnProperty(key)) { |
146 | properties.push(key); | 148 | if(key.serializable) { |
149 | properties.push(key); | ||
150 | } | ||
147 | } | 151 | } |
148 | } | 152 | } |
149 | 153 | ||
diff --git a/js/stage/binding-view.reel/binding-view.js b/js/stage/binding-view.reel/binding-view.js index 8ffc45c1..d76aab81 100755 --- a/js/stage/binding-view.reel/binding-view.js +++ b/js/stage/binding-view.reel/binding-view.js | |||
@@ -46,6 +46,7 @@ exports.BindingView = Montage.create(Component, { | |||
46 | this._selectedComponent = val; | 46 | this._selectedComponent = val; |
47 | this.application.ninja.objectsController.currentObject = this.selectedComponent; | 47 | this.application.ninja.objectsController.currentObject = this.selectedComponent; |
48 | var arrBindings = this.application.ninja.objectsController.currentObjectBindings; | 48 | var arrBindings = this.application.ninja.objectsController.currentObjectBindings; |
49 | debugger; | ||
49 | arrBindings.forEach(function(obj) { | 50 | arrBindings.forEach(function(obj) { |
50 | 51 | ||
51 | }.bind(this)); | 52 | }.bind(this)); |