Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(345)

Unified Diff: pkg/polymer/lib/src/instance.dart

Issue 507653004: update polymer to 0.3.5 (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: code review updates Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « pkg/polymer/lib/src/events.dart ('k') | pkg/polymer/lib/src/js/polymer/build.log » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/polymer/lib/src/instance.dart
diff --git a/pkg/polymer/lib/src/instance.dart b/pkg/polymer/lib/src/instance.dart
index c089bd2e4d314e8af437655b1bbdff340358b045..c9d5adea2d321aad19278e217e974aa89f8c2f79 100644
--- a/pkg/polymer/lib/src/instance.dart
+++ b/pkg/polymer/lib/src/instance.dart
@@ -352,10 +352,7 @@ abstract class Polymer implements Element, Observable, NodeBindExtension {
'incorrect binding types.');
}
prepareElement();
-
- // TODO(sorvell): replace when ShadowDOMPolyfill issue is corrected
- // https://github.com/Polymer/ShadowDOM/issues/420
- if (!isTemplateStagingDocument(ownerDocument) || _hasShadowDomPolyfill) {
+ if (!isTemplateStagingDocument(ownerDocument)) {
makeElementReady();
}
}
@@ -374,7 +371,6 @@ abstract class Polymer implements Element, Observable, NodeBindExtension {
_element = _getDeclaration(_name);
// install property storage
createPropertyObserver();
- // TODO (sorvell): temporarily open observer when created
openPropertyObserver();
// install boilerplate attributes
copyInstanceAttributes();
@@ -524,11 +520,6 @@ abstract class Polymer implements Element, Observable, NodeBindExtension {
void shadowRootReady(Node root) {
// locate nodes with id and store references to them in this.$ hash
marshalNodeReferences(root);
-
- // set up polymer gestures
- if (_PolymerGestures != null) {
- _PolymerGestures.callMethod('register', [root]);
- }
}
/// Locate nodes with id and store references to them in [$] hash.
@@ -1026,7 +1017,10 @@ abstract class Polymer implements Element, Observable, NodeBindExtension {
// by default supports 1 thing being bound.
events.forEach((type, methodName) {
// Dart note: the getEventHandler method is on our PolymerExpressions.
- on[type].listen(element.syntax.getEventHandler(this, this, methodName));
+ _PolymerGestures.callMethod(
+ 'addEventListener',
+ [this, type, Zone.current.bindUnaryCallback(
+ element.syntax.getEventHandler(this, this, methodName))]);
});
}
@@ -1173,7 +1167,7 @@ abstract class Polymer implements Element, Observable, NodeBindExtension {
if (scope == null) return;
- if (_ShadowCss != null) {
+ if (_hasShadowDomPolyfill) {
cssText = _shimCssText(cssText, scope is ShadowRoot ? scope.host : null);
}
var style = element.cssTextToScopeStyle(cssText,
« no previous file with comments | « pkg/polymer/lib/src/events.dart ('k') | pkg/polymer/lib/src/js/polymer/build.log » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698