Unverified Commit de55eece authored by Alexandre Ardhuin's avatar Alexandre Ardhuin Committed by GitHub

Export public API types from animation and physics libraries (#106757)

parent 4158a27a
...@@ -2,7 +2,6 @@ ...@@ -2,7 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
import 'dart:ui';
import 'package:flutter/animation.dart'; import 'package:flutter/animation.dart';
import '../common.dart'; import '../common.dart';
......
...@@ -160,6 +160,9 @@ ...@@ -160,6 +160,9 @@
/// explicit [Animation] to animate their properties. /// explicit [Animation] to animate their properties.
library animation; library animation;
// AnimationController can throw TickerCanceled
export 'package:flutter/scheduler.dart' show TickerCanceled;
export 'src/animation/animation.dart'; export 'src/animation/animation.dart';
export 'src/animation/animation_controller.dart'; export 'src/animation/animation_controller.dart';
export 'src/animation/animations.dart'; export 'src/animation/animations.dart';
......
...@@ -7,6 +7,10 @@ import 'package:flutter/foundation.dart'; ...@@ -7,6 +7,10 @@ import 'package:flutter/foundation.dart';
import 'tween.dart'; import 'tween.dart';
export 'dart:ui' show VoidCallback;
export 'tween.dart' show Animatable;
// Examples can assume: // Examples can assume:
// late AnimationController _controller; // late AnimationController _controller;
......
...@@ -14,7 +14,11 @@ import 'animation.dart'; ...@@ -14,7 +14,11 @@ import 'animation.dart';
import 'curves.dart'; import 'curves.dart';
import 'listener_helpers.dart'; import 'listener_helpers.dart';
export 'package:flutter/scheduler.dart' show TickerFuture, TickerCanceled; export 'package:flutter/physics.dart' show Simulation, SpringDescription;
export 'package:flutter/scheduler.dart' show TickerFuture, TickerProvider;
export 'animation.dart' show Animation, AnimationStatus;
export 'curves.dart' show Curve;
// Examples can assume: // Examples can assume:
// late AnimationController _controller, fadeAnimationController, sizeAnimationController; // late AnimationController _controller, fadeAnimationController, sizeAnimationController;
......
...@@ -11,6 +11,11 @@ import 'animation.dart'; ...@@ -11,6 +11,11 @@ import 'animation.dart';
import 'curves.dart'; import 'curves.dart';
import 'listener_helpers.dart'; import 'listener_helpers.dart';
export 'dart:ui' show VoidCallback;
export 'animation.dart' show Animation, AnimationStatus, AnimationStatusListener;
export 'curves.dart' show Curve;
// Examples can assume: // Examples can assume:
// late AnimationController controller; // late AnimationController controller;
......
...@@ -8,6 +8,8 @@ import 'dart:ui'; ...@@ -8,6 +8,8 @@ import 'dart:ui';
import 'package:flutter/foundation.dart'; import 'package:flutter/foundation.dart';
export 'dart:ui' show Offset;
/// An abstract class providing an interface for evaluating a parametric curve. /// An abstract class providing an interface for evaluating a parametric curve.
/// ///
/// A parametric curve transforms a parameter (hence the name) `t` along a curve /// A parametric curve transforms a parameter (hence the name) `t` along a curve
......
...@@ -7,6 +7,10 @@ import 'package:flutter/foundation.dart'; ...@@ -7,6 +7,10 @@ import 'package:flutter/foundation.dart';
import 'animation.dart'; import 'animation.dart';
export 'dart:ui' show VoidCallback;
export 'animation.dart' show AnimationStatus, AnimationStatusListener;
/// A mixin that helps listen to another object only when this object has registered listeners. /// A mixin that helps listen to another object only when this object has registered listeners.
/// ///
/// This mixin provides implementations of [didRegisterListener] and [didUnregisterListener], /// This mixin provides implementations of [didRegisterListener] and [didUnregisterListener],
......
...@@ -2,13 +2,16 @@ ...@@ -2,13 +2,16 @@
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
import 'dart:ui' show Color, Size, Rect; import 'dart:ui' show Color, Rect, Size;
import 'package:flutter/foundation.dart'; import 'package:flutter/foundation.dart';
import 'animation.dart';
import 'animations.dart'; import 'animations.dart';
import 'curves.dart';
export 'dart:ui' show Color, Rect, Size;
export 'animation.dart' show Animation;
export 'curves.dart' show Curve;
// Examples can assume: // Examples can assume:
// late Animation<Offset> _animation; // late Animation<Offset> _animation;
......
...@@ -2,10 +2,10 @@ ...@@ -2,10 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be // Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file. // found in the LICENSE file.
import 'animation.dart';
import 'tween.dart'; import 'tween.dart';
export 'tween.dart' show Animatable;
// Examples can assume: // Examples can assume:
// late AnimationController myAnimationController; // late AnimationController myAnimationController;
......
...@@ -7,7 +7,6 @@ import 'dart:ui' show lerpDouble; ...@@ -7,7 +7,6 @@ import 'dart:ui' show lerpDouble;
import 'package:flutter/animation.dart'; import 'package:flutter/animation.dart';
import 'package:flutter/foundation.dart'; import 'package:flutter/foundation.dart';
import 'package:flutter/painting.dart';
// How close the begin and end points must be to an axis to be considered // How close the begin and end points must be to an axis to be considered
// vertical or horizontal. // vertical or horizontal.
......
...@@ -6,6 +6,8 @@ import 'package:flutter/foundation.dart'; ...@@ -6,6 +6,8 @@ import 'package:flutter/foundation.dart';
import 'simulation.dart'; import 'simulation.dart';
export 'simulation.dart' show Simulation;
/// A simulation that applies limits to another simulation. /// A simulation that applies limits to another simulation.
/// ///
/// The limits are only applied to the other simulation's outputs. For example, /// The limits are only applied to the other simulation's outputs. For example,
......
...@@ -7,7 +7,8 @@ import 'dart:math' as math; ...@@ -7,7 +7,8 @@ import 'dart:math' as math;
import 'package:flutter/foundation.dart'; import 'package:flutter/foundation.dart';
import 'simulation.dart'; import 'simulation.dart';
import 'tolerance.dart';
export 'tolerance.dart' show Tolerance;
/// A simulation that applies a drag to slow a particle down. /// A simulation that applies a drag to slow a particle down.
/// ///
......
...@@ -6,6 +6,8 @@ import 'package:flutter/foundation.dart'; ...@@ -6,6 +6,8 @@ import 'package:flutter/foundation.dart';
import 'tolerance.dart'; import 'tolerance.dart';
export 'tolerance.dart' show Tolerance;
/// The base class for all simulations. /// The base class for all simulations.
/// ///
/// A simulation models an object, in a one-dimensional space, on which particular /// A simulation models an object, in a one-dimensional space, on which particular
......
...@@ -9,6 +9,8 @@ import 'package:flutter/foundation.dart'; ...@@ -9,6 +9,8 @@ import 'package:flutter/foundation.dart';
import 'simulation.dart'; import 'simulation.dart';
import 'utils.dart'; import 'utils.dart';
export 'tolerance.dart' show Tolerance;
/// Structure that describes a spring's constants. /// Structure that describes a spring's constants.
/// ///
/// Used to configure a [SpringSimulation]. /// Used to configure a [SpringSimulation].
......
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
import 'package:flutter/animation.dart'; import 'package:flutter/animation.dart';
import 'package:flutter/foundation.dart'; import 'package:flutter/foundation.dart';
import 'package:flutter/scheduler.dart';
import 'box.dart'; import 'box.dart';
import 'layer.dart'; import 'layer.dart';
......
...@@ -7,9 +7,7 @@ import 'dart:math' as math; ...@@ -7,9 +7,7 @@ import 'dart:math' as math;
import 'package:flutter/foundation.dart'; import 'package:flutter/foundation.dart';
import 'package:flutter/gestures.dart'; import 'package:flutter/gestures.dart';
import 'package:flutter/physics.dart';
import 'package:flutter/rendering.dart'; import 'package:flutter/rendering.dart';
import 'package:flutter/scheduler.dart';
import 'basic.dart'; import 'basic.dart';
import 'framework.dart'; import 'framework.dart';
......
...@@ -4,7 +4,6 @@ ...@@ -4,7 +4,6 @@
import 'package:flutter/gestures.dart'; import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter/physics.dart';
import 'package:flutter/rendering.dart'; import 'package:flutter/rendering.dart';
import 'package:flutter_test/flutter_test.dart'; import 'package:flutter_test/flutter_test.dart';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment