| Index: client/html/src/DocumentFragmentWrappingImplementation.dart
|
| diff --git a/client/html/src/DocumentFragmentWrappingImplementation.dart b/client/html/src/DocumentFragmentWrappingImplementation.dart
|
| index 612c3f1a9a953a7b362d7ca7c2626473388dc904..41bb7d184e4a24564916ea4dc20afcde8d9a7ee9 100644
|
| --- a/client/html/src/DocumentFragmentWrappingImplementation.dart
|
| +++ b/client/html/src/DocumentFragmentWrappingImplementation.dart
|
| @@ -1,4 +1,4 @@
|
| -// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
|
| +// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
|
| // for details. All rights reserved. Use of this source code is governed by a
|
| // BSD-style license that can be found in the LICENSE file.
|
|
|
| @@ -132,11 +132,6 @@ class EmptyStyleDeclaration extends CSSStyleDeclarationWrappingImplementation {
|
| }
|
| }
|
|
|
| -Future<CSSStyleDeclaration> _emptyStyleFuture() {
|
| - return _createMeasurementFuture(() => new EmptyStyleDeclaration(),
|
| - new Completer<CSSStyleDeclaration>());
|
| -}
|
| -
|
| class EmptyElementRect implements ElementRect {
|
| final ClientRect client = const SimpleClientRect(0, 0, 0, 0);
|
| final ClientRect offset = const SimpleClientRect(0, 0, 0, 0);
|
| @@ -234,9 +229,10 @@ class DocumentFragmentWrappingImplementation extends NodeWrappingImplementation
|
| return _on;
|
| }
|
|
|
| - Future<ElementRect> get rect() {
|
| - return _createMeasurementFuture(() => const EmptyElementRect(),
|
| - new Completer<ElementRect>());
|
| + ElementRect get rect() {
|
| + // A document fragment can never be attached to a Document so it always
|
| + // safe to measure.
|
| + return const EmptyElementRect();
|
| }
|
|
|
| Element query(String selectors) =>
|
| @@ -269,10 +265,9 @@ class DocumentFragmentWrappingImplementation extends NodeWrappingImplementation
|
| Set<String> get classes() => new Set<String>();
|
| Map<String, String> get dataAttributes() => const {};
|
| CSSStyleDeclaration get style() => new EmptyStyleDeclaration();
|
| - Future<CSSStyleDeclaration> get computedStyle() =>
|
| - _emptyStyleFuture();
|
| - Future<CSSStyleDeclaration> getComputedStyle(String pseudoElement) =>
|
| - _emptyStyleFuture();
|
| + CSSStyleDeclaration get computedStyle() => new EmptyStyleDeclaration();
|
| + CSSStyleDeclaration getComputedStyle(String pseudoElement) =>
|
| + new EmptyStyleDeclaration();
|
| bool matchesSelector([String selectors]) => false;
|
|
|
| // Imperative Element methods are made into no-ops, as they are on parentless
|
|
|