diff --git a/polymer.html b/polymer.html
index d299737150..fa721c78bc 100644
--- a/polymer.html
+++ b/polymer.html
@@ -65,7 +65,7 @@
// setup gestures
this._setupGestures();
// manage configuration
- this._setupConfigure();
+ this._setupConfigure(this.__data__);
// setup style properties
this._setupStyleProperties();
// setup debouncers
diff --git a/src/lib/base.html b/src/lib/base.html
index d98f19bd6b..726e54cdd3 100644
--- a/src/lib/base.html
+++ b/src/lib/base.html
@@ -64,6 +64,17 @@
},
createdCallback: function() {
+ if (Polymer.Settings.enableInert && this.hasAttribute('is-inert')) {
+ this.__data__ = {
+ isInert: true
+ };
+ this._propertySetter = inertPropertySetter;
+ } else {
+ this.__initialize();
+ }
+ },
+
+ __initialize: function() {
if (!this.__hasRegisterFinished) {
this._ensureRegisterFinished(this.__proto__);
}
@@ -288,6 +299,32 @@
Polymer.Base = Polymer.Base.chainObject(Polymer.Base, HTMLElement.prototype);
Polymer.BaseDescriptors = {};
+ if (Polymer.Settings.enableInert) {
+
+ var inertPropertySetter = function(property, value) {
+ this.__data__[property] = value;
+ }
+
+ var inertDesc = {
+ configurable: true,
+ writeable: true,
+ set: function(val) {
+ if (!val && this.isInert) {
+ this.__data__.isInert = false;
+ this._propertySetter = Polymer.Bind._modelApi._propertySetter;
+ this.__initialize();
+ this.removeAttribute('is-inert');
+ }
+ },
+ get: function() {
+ return this.__data__.isInert;
+ }
+ }
+
+ Polymer.BaseDescriptors.isInert = inertDesc;
+ Object.defineProperty(Polymer.Base, 'isInert', inertDesc);
+ }
+
if (window.CustomElements) {
Polymer.instanceof = CustomElements.instanceof;
} else {
diff --git a/src/lib/polymer-bootstrap.html b/src/lib/polymer-bootstrap.html
index ef9c332902..28197bee7d 100644
--- a/src/lib/polymer-bootstrap.html
+++ b/src/lib/polymer-bootstrap.html
@@ -70,6 +70,9 @@
}
Polymer.Class = function(prototype) {
+ if (!prototype.factoryImpl) {
+ prototype.factoryImpl = function() {}
+ }
return desugar(prototype).constructor;
}