From acdd242616f77616f1f3f90e0389c4c98161bcb4 Mon Sep 17 00:00:00 2001 From: Steven Orvell Date: Tue, 20 Oct 2015 13:07:50 -0700 Subject: [PATCH] Use flattened list of properties for fast access during configuration and attribute->property --- polymer-micro.html | 2 ++ polymer-mini.html | 2 ++ polymer.html | 2 ++ src/micro/attributes.html | 25 ++++++++++++++++--------- src/micro/properties.html | 34 +++++++++++++++++++++++++++++++++- src/standard/configure.html | 10 +++++++++- 6 files changed, 64 insertions(+), 11 deletions(-) diff --git a/polymer-micro.html b/polymer-micro.html index ffbc2aac3d..f443f8658e 100644 --- a/polymer-micro.html +++ b/polymer-micro.html @@ -33,6 +33,8 @@ this._prepBehaviors(); // factory this._prepConstructor(); + // fast access to property info + this._prepPropertyInfo(); }, _prepBehavior: function(b) { diff --git a/polymer-mini.html b/polymer-mini.html index 98e2e45d65..668fb54502 100644 --- a/polymer-mini.html +++ b/polymer-mini.html @@ -34,6 +34,8 @@ this._prepTemplate(); // dom encapsulation this._prepShady(); + // fast access to property info + this._prepPropertyInfo(); }, _prepBehavior: function(b) { diff --git a/polymer.html b/polymer.html index b1dafa7c2d..a5c82fd745 100644 --- a/polymer.html +++ b/polymer.html @@ -48,6 +48,8 @@ this._prepBindings(); // dom encapsulation this._prepShady(); + // fast access to property info + this._prepPropertyInfo(); }, _prepBehavior: function(b) { diff --git a/src/micro/attributes.html b/src/micro/attributes.html index 679ca6e19f..f4ac4d8d88 100644 --- a/src/micro/attributes.html +++ b/src/micro/attributes.html @@ -91,20 +91,27 @@ }, _takeAttributesToModel: function(model) { - for (var i=0, l=this.attributes.length; i