From 557473639c1854d2e545f542d5f8656a040d575c Mon Sep 17 00:00:00 2001 From: Armen Kesablyan Date: Wed, 6 Jun 2012 14:42:12 -0700 Subject: Object Controller Signed-off-by: Armen Kesablyan --- js/controllers/objects-controller.js | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'js/controllers/objects-controller.js') 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, { if(descriptors.hasOwnProperty(property)) { descriptor = descriptors[property]; - bindingArgsObject = { - sourceObject : object, - sourceObjectPropertyPath : property, - boundObject : descriptor.boundObject, - boundObjectPropertyPath : descriptor.boundObjectPropertyPath, - oneway : descriptor.oneway - }; - - bindingsArray.push(bindingArgsObject); + bindingArgsObject = { + sourceObject : object, + sourceObjectPropertyPath : property, + boundObject : descriptor.boundObject, + boundObjectPropertyPath : descriptor.boundObjectPropertyPath, + oneway : descriptor.oneway + }; + + bindingsArray.push(bindingArgsObject); } } } @@ -125,6 +125,7 @@ var objectsController = exports.ObjectsController = Montage.create(Component, { } return prototypes.map(function(proto) { + var metadata = proto._montage_metadata, objectName = (metadata) ? metadata.objectName : "Object"; @@ -142,8 +143,11 @@ var objectsController = exports.ObjectsController = Montage.create(Component, { var properties = []; for(var key in object) { + debugger; if(object.hasOwnProperty(key)) { - properties.push(key); + if(key.serializable) { + properties.push(key); + } } } -- cgit v1.2.3