From 6161d54eb6d7cfd47acf563ac97ddcab567ec63d Mon Sep 17 00:00:00 2001 From: amirh Date: Wed, 1 Nov 2017 09:24:30 -0700 Subject: [PATCH] Move AbstractNode to lib/foundation. (#12789) (in preparation for moving the semantics stuff out of rendering) --- packages/flutter/lib/foundation.dart | 1 + packages/flutter/lib/rendering.dart | 1 - packages/flutter/lib/src/{rendering => foundation}/node.dart | 2 +- packages/flutter/lib/src/rendering/layer.dart | 1 - packages/flutter/lib/src/rendering/object.dart | 1 - packages/flutter/lib/src/rendering/semantics.dart | 1 - .../flutter/test/rendering/non_render_object_root_test.dart | 1 + 7 files changed, 3 insertions(+), 5 deletions(-) rename packages/flutter/lib/src/{rendering => foundation}/node.dart (99%) diff --git a/packages/flutter/lib/foundation.dart b/packages/flutter/lib/foundation.dart index 18c2099c36..ae738b57ea 100644 --- a/packages/flutter/lib/foundation.dart +++ b/packages/flutter/lib/foundation.dart @@ -40,6 +40,7 @@ export 'src/foundation/collections.dart'; export 'src/foundation/debug.dart'; export 'src/foundation/diagnostics.dart'; export 'src/foundation/licenses.dart'; +export 'src/foundation/node.dart'; export 'src/foundation/observer_list.dart'; export 'src/foundation/platform.dart'; export 'src/foundation/print.dart'; diff --git a/packages/flutter/lib/rendering.dart b/packages/flutter/lib/rendering.dart index af00b837d0..f2eb4291eb 100644 --- a/packages/flutter/lib/rendering.dart +++ b/packages/flutter/lib/rendering.dart @@ -42,7 +42,6 @@ export 'src/rendering/flow.dart'; export 'src/rendering/image.dart'; export 'src/rendering/layer.dart'; export 'src/rendering/list_body.dart'; -export 'src/rendering/node.dart'; export 'src/rendering/object.dart'; export 'src/rendering/paragraph.dart'; export 'src/rendering/performance_overlay.dart'; diff --git a/packages/flutter/lib/src/rendering/node.dart b/packages/flutter/lib/src/foundation/node.dart similarity index 99% rename from packages/flutter/lib/src/rendering/node.dart rename to packages/flutter/lib/src/foundation/node.dart index 31ef2ab114..0d3e265148 100644 --- a/packages/flutter/lib/src/rendering/node.dart +++ b/packages/flutter/lib/src/foundation/node.dart @@ -2,7 +2,7 @@ // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. -import 'package:flutter/foundation.dart'; +import 'package:meta/meta.dart'; /// An abstract node in a tree. /// diff --git a/packages/flutter/lib/src/rendering/layer.dart b/packages/flutter/lib/src/rendering/layer.dart index d789dd2b00..2375fa7f66 100644 --- a/packages/flutter/lib/src/rendering/layer.dart +++ b/packages/flutter/lib/src/rendering/layer.dart @@ -11,7 +11,6 @@ import 'package:flutter/painting.dart'; import 'package:vector_math/vector_math_64.dart'; import 'debug.dart'; -import 'node.dart'; /// A composited layer. /// diff --git a/packages/flutter/lib/src/rendering/object.dart b/packages/flutter/lib/src/rendering/object.dart index a6e0c8a074..b0cb1a645e 100644 --- a/packages/flutter/lib/src/rendering/object.dart +++ b/packages/flutter/lib/src/rendering/object.dart @@ -14,7 +14,6 @@ import 'package:vector_math/vector_math_64.dart'; import 'binding.dart'; import 'debug.dart'; import 'layer.dart'; -import 'node.dart'; import 'semantics.dart'; export 'package:flutter/foundation.dart' show FlutterError, InformationCollector, DiagnosticsNode, DiagnosticsProperty, StringProperty, DoubleProperty, EnumProperty, FlagProperty, IntProperty, DiagnosticPropertiesBuilder; diff --git a/packages/flutter/lib/src/rendering/semantics.dart b/packages/flutter/lib/src/rendering/semantics.dart index edc5939521..205a622b08 100644 --- a/packages/flutter/lib/src/rendering/semantics.dart +++ b/packages/flutter/lib/src/rendering/semantics.dart @@ -12,7 +12,6 @@ import 'package:flutter/services.dart'; import 'package:vector_math/vector_math_64.dart'; import 'debug.dart'; -import 'node.dart'; import 'semantics_event.dart'; export 'dart:ui' show SemanticsAction; diff --git a/packages/flutter/test/rendering/non_render_object_root_test.dart b/packages/flutter/test/rendering/non_render_object_root_test.dart index e22720314e..037654a155 100644 --- a/packages/flutter/test/rendering/non_render_object_root_test.dart +++ b/packages/flutter/test/rendering/non_render_object_root_test.dart @@ -3,6 +3,7 @@ // found in the LICENSE file. import 'package:flutter/material.dart'; +import 'package:flutter/foundation.dart'; import 'package:flutter/rendering.dart'; import 'package:test/test.dart';