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

Side by Side Diff: pkg/polymer/lib/src/instance.dart

Issue 111933002: Fix != null bug (issue 14751) (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | pkg/polymer/pubspec.yaml » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 part of polymer; 5 part of polymer;
6 6
7 /** 7 /**
8 * Use this annotation to publish a field as an attribute. For example: 8 * Use this annotation to publish a field as an attribute. For example:
9 * 9 *
10 * class MyPlaybackElement extends PolymerElement { 10 * class MyPlaybackElement extends PolymerElement {
(...skipping 917 matching lines...) Expand 10 before | Expand all | Expand 10 after
928 } 928 }
929 } 929 }
930 } 930 }
931 931
932 Node findStyleController() { 932 Node findStyleController() {
933 if (js.context != null && js.context['ShadowDOMPolyfill'] != null) { 933 if (js.context != null && js.context['ShadowDOMPolyfill'] != null) {
934 return document.querySelector('head'); // get wrapped <head>. 934 return document.querySelector('head'); // get wrapped <head>.
935 } else { 935 } else {
936 // find the shadow root that contains this element 936 // find the shadow root that contains this element
937 var n = this; 937 var n = this;
938 while (n.parentNode) { 938 while (n.parentNode != null) {
939 n = n.parentNode; 939 n = n.parentNode;
940 } 940 }
941 return identical(n, document) ? document.head : n; 941 return identical(n, document) ? document.head : n;
942 } 942 }
943 } 943 }
944 944
945 bool scopeHasElementStyle(scope, descriptor) { 945 bool scopeHasElementStyle(scope, descriptor) {
946 var rule = '$_STYLE_SCOPE_ATTRIBUTE=$localName-$descriptor'; 946 var rule = '$_STYLE_SCOPE_ATTRIBUTE=$localName-$descriptor';
947 return scope.querySelector('style[$rule]') != null; 947 return scope.querySelector('style[$rule]') != null;
948 } 948 }
(...skipping 139 matching lines...) Expand 10 before | Expand all | Expand 10 after
1088 1088
1089 class _PropertyValue { 1089 class _PropertyValue {
1090 Object oldValue, newValue; 1090 Object oldValue, newValue;
1091 _PropertyValue(this.oldValue); 1091 _PropertyValue(this.oldValue);
1092 } 1092 }
1093 1093
1094 class _PolymerExpressionsWithEventDelegate extends PolymerExpressions { 1094 class _PolymerExpressionsWithEventDelegate extends PolymerExpressions {
1095 prepareBinding(String path, name, node) => 1095 prepareBinding(String path, name, node) =>
1096 Polymer.prepareBinding(path, name, node, super.prepareBinding); 1096 Polymer.prepareBinding(path, name, node, super.prepareBinding);
1097 } 1097 }
OLDNEW
« no previous file with comments | « no previous file | pkg/polymer/pubspec.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698