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

This commit is contained in:
Alexandre Ardhuin 2022-06-29 07:26:09 +02:00 committed by GitHub
parent 4158a27a74
commit de55eeceed
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
17 changed files with 39 additions and 13 deletions

View file

@ -2,7 +2,6 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import 'dart:ui';
import 'package:flutter/animation.dart';
import '../common.dart';

View file

@ -160,6 +160,9 @@
/// explicit [Animation] to animate their properties.
library animation;
// AnimationController can throw TickerCanceled
export 'package:flutter/scheduler.dart' show TickerCanceled;
export 'src/animation/animation.dart';
export 'src/animation/animation_controller.dart';
export 'src/animation/animations.dart';

View file

@ -7,6 +7,10 @@ import 'package:flutter/foundation.dart';
import 'tween.dart';
export 'dart:ui' show VoidCallback;
export 'tween.dart' show Animatable;
// Examples can assume:
// late AnimationController _controller;

View file

@ -14,7 +14,11 @@ import 'animation.dart';
import 'curves.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:
// late AnimationController _controller, fadeAnimationController, sizeAnimationController;

View file

@ -11,6 +11,11 @@ import 'animation.dart';
import 'curves.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:
// late AnimationController controller;

View file

@ -8,6 +8,8 @@ import 'dart:ui';
import 'package:flutter/foundation.dart';
export 'dart:ui' show Offset;
/// An abstract class providing an interface for evaluating a parametric curve.
///
/// A parametric curve transforms a parameter (hence the name) `t` along a curve

View file

@ -7,6 +7,10 @@ import 'package:flutter/foundation.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.
///
/// This mixin provides implementations of [didRegisterListener] and [didUnregisterListener],

View file

@ -2,13 +2,16 @@
// Use of this source code is governed by a BSD-style license that can be
// 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 'animation.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:
// late Animation<Offset> _animation;

View file

@ -2,10 +2,10 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
import 'animation.dart';
import 'tween.dart';
export 'tween.dart' show Animatable;
// Examples can assume:
// late AnimationController myAnimationController;

View file

@ -7,7 +7,6 @@ import 'dart:ui' show lerpDouble;
import 'package:flutter/animation.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
// vertical or horizontal.

View file

@ -6,6 +6,8 @@ import 'package:flutter/foundation.dart';
import 'simulation.dart';
export 'simulation.dart' show Simulation;
/// A simulation that applies limits to another simulation.
///
/// The limits are only applied to the other simulation's outputs. For example,

View file

@ -7,7 +7,8 @@ import 'dart:math' as math;
import 'package:flutter/foundation.dart';
import 'simulation.dart';
import 'tolerance.dart';
export 'tolerance.dart' show Tolerance;
/// A simulation that applies a drag to slow a particle down.
///

View file

@ -6,6 +6,8 @@ import 'package:flutter/foundation.dart';
import 'tolerance.dart';
export 'tolerance.dart' show Tolerance;
/// The base class for all simulations.
///
/// A simulation models an object, in a one-dimensional space, on which particular

View file

@ -9,6 +9,8 @@ import 'package:flutter/foundation.dart';
import 'simulation.dart';
import 'utils.dart';
export 'tolerance.dart' show Tolerance;
/// Structure that describes a spring's constants.
///
/// Used to configure a [SpringSimulation].

View file

@ -4,7 +4,6 @@
import 'package:flutter/animation.dart';
import 'package:flutter/foundation.dart';
import 'package:flutter/scheduler.dart';
import 'box.dart';
import 'layer.dart';

View file

@ -7,9 +7,7 @@ import 'dart:math' as math;
import 'package:flutter/foundation.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/physics.dart';
import 'package:flutter/rendering.dart';
import 'package:flutter/scheduler.dart';
import 'basic.dart';
import 'framework.dart';

View file

@ -4,7 +4,6 @@
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter/physics.dart';
import 'package:flutter/rendering.dart';
import 'package:flutter_test/flutter_test.dart';