diff --git a/packages/flutter/lib/src/animation/animations.dart b/packages/flutter/lib/src/animation/animations.dart index 1eb11464f0..f2eb3ee7e0 100644 --- a/packages/flutter/lib/src/animation/animations.dart +++ b/packages/flutter/lib/src/animation/animations.dart @@ -79,9 +79,9 @@ class AlwaysStoppedAnimation extends Animation { /// Creates an [AlwaysStoppedAnimation] with the given value. /// /// Since the [value] and [status] of an [AlwaysStoppedAnimation] can never - /// change, the listeners can never be invoked. It is therefore safe to reuse + /// change, the listeners can never be called. It is therefore safe to reuse /// an [AlwaysStoppedAnimation] instance in multiple places. If the [value] to - /// be used is known at compile time, the constructor should be invoked as a + /// be used is known at compile time, the constructor should be called as a /// `const` constructor. const AlwaysStoppedAnimation(this.value); diff --git a/packages/flutter/lib/src/animation/listener_helpers.dart b/packages/flutter/lib/src/animation/listener_helpers.dart index cf125b7453..7b8e4c1bd3 100644 --- a/packages/flutter/lib/src/animation/listener_helpers.dart +++ b/packages/flutter/lib/src/animation/listener_helpers.dart @@ -55,7 +55,7 @@ abstract class AnimationEagerListenerMixin implements _ListenerMixin { } /// A mixin that implements the addListener/removeListener protocol and notifies -/// all the registered listeners when notifyListeners is invoked. +/// all the registered listeners when notifyListeners is called. abstract class AnimationLocalListenersMixin extends _ListenerMixin { final List _listeners = []; @@ -88,7 +88,7 @@ abstract class AnimationLocalListenersMixin extends _ListenerMixin { /// A mixin that implements the addStatusListener/removeStatusListener protocol /// and notifies all the registered listeners when notifyStatusListeners is -/// invoked. +/// called. abstract class AnimationLocalStatusListenersMixin extends _ListenerMixin { final List _statusListeners = []; diff --git a/packages/flutter/lib/src/cassowary/README.md b/packages/flutter/lib/src/cassowary/README.md index c8e520e3e6..b8ec375989 100644 --- a/packages/flutter/lib/src/cassowary/README.md +++ b/packages/flutter/lib/src/cassowary/README.md @@ -7,7 +7,7 @@ This is an implementation of the Cassowary constraint solving algorithm in Dart. A solver is the object that accepts constraints and updates member variables in an attempt to satisfy the same. It is rarely the case that the user will have to create a solver. Instead, one will be vended by Flutter. # Parameters -In order to create constraints, the user needs to take specific parameter objects vended by elements in the view hierarchy and create expression from these. Constraints can then be obtained from these expressions. If the solver needs to update these parameters to satisfy constraints, it will invoke callbacks on these parameters. +In order to create constraints, the user needs to take specific parameter objects vended by elements in the view hierarchy and create expression from these. Constraints can then be obtained from these expressions. If the solver needs to update these parameters to satisfy constraints, it will call callbacks on these parameters. # Constructing Constraints diff --git a/packages/flutter/lib/src/foundation/assertions.dart b/packages/flutter/lib/src/foundation/assertions.dart index 79dc1a3d81..943e6cda10 100644 --- a/packages/flutter/lib/src/foundation/assertions.dart +++ b/packages/flutter/lib/src/foundation/assertions.dart @@ -45,7 +45,7 @@ class FlutterErrorDetails { /// StackTrace objects are opaque except for their [toString] function. /// /// If this field is not null, then the [stackFilter] callback, if any, will - /// be invoked with the result of calling [toString] on this object and + /// be called with the result of calling [toString] on this object and /// splitting that result on line breaks. If there's no [stackFilter] /// callback, then [FlutterError.defaultStackFilter] is used instead. That /// function expects the stack to be in the format used by @@ -77,11 +77,11 @@ class FlutterErrorDetails { /// This won't be called if [stack] is null. final IterableFilter stackFilter; - /// A callback which, when invoked with a [StringBuffer] will write to that buffer + /// A callback which, when called with a [StringBuffer] will write to that buffer /// information that could help with debugging the problem. /// /// Information collector callbacks can be expensive, so the generated information - /// should be cached, rather than the callback being invoked multiple times. + /// should be cached, rather than the callback being called multiple times. /// /// The text written to the information argument may contain newlines but should /// not end with a newline. @@ -139,7 +139,7 @@ class FlutterError extends AssertionError { /// Called whenever the Flutter framework catches an error. /// - /// The default behavior is to invoke [dumpErrorToConsole]. + /// The default behavior is to call [dumpErrorToConsole]. /// /// You can set this to your own function to override this default behavior. /// For example, you could report all errors to your server. diff --git a/packages/flutter/lib/src/foundation/basic_types.dart b/packages/flutter/lib/src/foundation/basic_types.dart index 413370aee3..42b517f080 100644 --- a/packages/flutter/lib/src/foundation/basic_types.dart +++ b/packages/flutter/lib/src/foundation/basic_types.dart @@ -14,9 +14,9 @@ typedef void ValueChanged(T value); /// Signature for callbacks that report that a value has been set. /// /// This is the same signature as [ValueChanged], but is used when the -/// callback is invoked even if the underlying value has not changed. +/// callback is called even if the underlying value has not changed. /// For example, service extensions use this callback because they -/// invoke the callback whenever the extension is invoked with a +/// call the callback whenever the extension is called with a /// value, regardless of whether the given value is new or not. typedef void ValueSetter(T value); diff --git a/packages/flutter/lib/src/foundation/binding.dart b/packages/flutter/lib/src/foundation/binding.dart index 9f081880e8..5209dcdba6 100644 --- a/packages/flutter/lib/src/foundation/binding.dart +++ b/packages/flutter/lib/src/foundation/binding.dart @@ -125,8 +125,7 @@ abstract class BindingBase { /// name "ext.flutter.name"), which takes no arguments and returns /// no value. /// - /// Invokes the `callback` callback when the service extension is - /// invoked. + /// Calls the `callback` callback when the service extension is called. void registerSignalServiceExtension({ @required String name, @required VoidCallback callback @@ -149,11 +148,11 @@ abstract class BindingBase { /// than "true" is considered equivalent to "false". Other arguments /// are ignored.) /// - /// Invokes the `getter` callback to obtain the value when - /// responding to the service extension method being invoked. + /// Calls the `getter` callback to obtain the value when + /// responding to the service extension method being called. /// - /// Invokes the `setter` callback with the new value when the - /// service extension method is invoked with a new value. + /// Calls the `setter` callback with the new value when the + /// service extension method is called with a new value. void registerBoolServiceExtension({ String name, @required ValueGetter getter, @@ -178,11 +177,11 @@ abstract class BindingBase { /// that can be parsed by [double.parse], and can be omitted to read /// the current value. (Other arguments are ignored.) /// - /// Invokes the `getter` callback to obtain the value when - /// responding to the service extension method being invoked. + /// Calls the `getter` callback to obtain the value when + /// responding to the service extension method being called. /// - /// Invokes the `setter` callback with the new value when the - /// service extension method is invoked with a new value. + /// Calls the `setter` callback with the new value when the + /// service extension method is called with a new value. void registerNumericServiceExtension({ @required String name, @required ValueGetter getter, @@ -202,7 +201,7 @@ abstract class BindingBase { } /// Registers a service extension method with the given name (full - /// name "ext.flutter.name"). The given callback is invoked when the + /// name "ext.flutter.name"). The given callback is called when the /// extension method is called. The callback must return a [Future] /// that either eventually completes to a return value in the form /// of a name/value map where the values can all be converted to diff --git a/packages/flutter/lib/src/gestures/multitap.dart b/packages/flutter/lib/src/gestures/multitap.dart index 0f7170eb26..b8869cae51 100644 --- a/packages/flutter/lib/src/gestures/multitap.dart +++ b/packages/flutter/lib/src/gestures/multitap.dart @@ -81,7 +81,7 @@ class DoubleTapGestureRecognizer extends GestureRecognizer { // _firstTap records the successful tap. // Second tap in progress: Much like the "first tap in progress" state, but // _firstTap is non-null. If a tap completes successfully while in this - // state, the callback is invoked and the state is reset. + // state, the callback is called and the state is reset. // There are various other scenarios that cause the state to reset: // - All in-progress taps are rejected (by time, distance, pointercancel, etc) // - The long timer between taps expires diff --git a/packages/flutter/lib/src/material/app.dart b/packages/flutter/lib/src/material/app.dart index 129a4627c3..85c2aa5f95 100644 --- a/packages/flutter/lib/src/material/app.dart +++ b/packages/flutter/lib/src/material/app.dart @@ -99,7 +99,7 @@ class MaterialApp extends StatefulWidget { /// in this map for the [Navigator.defaultRouteName] route (`'/'`). /// /// If a route is requested that is not specified in this table (or - /// by [home]), then the [onGenerateRoute] callback is invoked to + /// by [home]), then the [onGenerateRoute] callback is called to /// build the page instead. final Map routes; @@ -107,7 +107,7 @@ class MaterialApp extends StatefulWidget { /// named route. final RouteFactory onGenerateRoute; - /// Callback that is invoked when the operating system changes the + /// Callback that is called when the operating system changes the /// current locale. final LocaleChangedCallback onLocaleChanged; diff --git a/packages/flutter/lib/src/material/button.dart b/packages/flutter/lib/src/material/button.dart index 66bce53e45..83614410e6 100644 --- a/packages/flutter/lib/src/material/button.dart +++ b/packages/flutter/lib/src/material/button.dart @@ -167,7 +167,7 @@ class MaterialButton extends StatefulWidget { /// Defaults to the value from the current [ButtonTheme]. final EdgeInsets padding; - /// The callback that is invoked when the button is tapped or otherwise activated. + /// The callback that is called when the button is tapped or otherwise activated. /// /// If this is set to null, the button will be disabled. final VoidCallback onPressed; diff --git a/packages/flutter/lib/src/material/data_table.dart b/packages/flutter/lib/src/material/data_table.dart index 878dd035dc..67cae6a294 100644 --- a/packages/flutter/lib/src/material/data_table.dart +++ b/packages/flutter/lib/src/material/data_table.dart @@ -62,7 +62,7 @@ class DataColumn { /// right-aligned. final bool numeric; - /// Invoked when the user asks to sort the table using this column. + /// Called when the user asks to sort the table using this column. /// /// If null, the column will not be considered sortable. /// @@ -99,7 +99,7 @@ class DataRow { /// If the table never changes once created, no key is necessary. final LocalKey key; - /// Invoked when the user selects or unselects a selectable row. + /// Called when the user selects or unselects a selectable row. /// /// If this is not null, then the row is selectable. The current /// selection state of the row is given by [selected]. @@ -179,9 +179,9 @@ class DataCell { /// the icon will have no effect. final bool showEditIcon; - /// Invoked if the cell is tapped. + /// Called if the cell is tapped. /// - /// If non-null, tapping the cell will invoke this callback. If + /// If non-null, tapping the cell will call this callback. If /// null, tapping the cell will attempt to select the row (if /// [TableRow.onSelectChanged] is provided). final VoidCallback onTap; diff --git a/packages/flutter/lib/src/material/debug.dart b/packages/flutter/lib/src/material/debug.dart index f645a362fb..3e53798594 100644 --- a/packages/flutter/lib/src/material/debug.dart +++ b/packages/flutter/lib/src/material/debug.dart @@ -12,7 +12,7 @@ import 'scaffold.dart'; /// Used by many material design widgets to make sure that they are /// only used in contexts where they can print ink onto some material. /// -/// To invoke this function, use the following pattern, typically in the +/// To call this function, use the following pattern, typically in the /// relevant Widget's [build] method: /// /// ```dart @@ -51,7 +51,7 @@ bool debugCheckHasMaterial(BuildContext context) { /// For example, the [AppBar] in some situations requires a Scaffold /// to do the right thing with scrolling. /// -/// To invoke this function, use the following pattern, typically in the +/// To call this function, use the following pattern, typically in the /// relevant Widget's [build] method: /// /// ```dart diff --git a/packages/flutter/lib/src/material/flat_button.dart b/packages/flutter/lib/src/material/flat_button.dart index 0c08aad94c..cd6cf5b420 100644 --- a/packages/flutter/lib/src/material/flat_button.dart +++ b/packages/flutter/lib/src/material/flat_button.dart @@ -52,7 +52,7 @@ class FlatButton extends StatelessWidget { assert(child != null); } - /// The callback that is invoked when the button is tapped or otherwise activated. + /// The callback that is called when the button is tapped or otherwise activated. /// /// If this is set to null, the button will be disabled. final VoidCallback onPressed; diff --git a/packages/flutter/lib/src/material/floating_action_button.dart b/packages/flutter/lib/src/material/floating_action_button.dart index 90fdaa24a9..0172a3c689 100644 --- a/packages/flutter/lib/src/material/floating_action_button.dart +++ b/packages/flutter/lib/src/material/floating_action_button.dart @@ -67,7 +67,7 @@ class FloatingActionButton extends StatefulWidget { /// Defaults to the accent color of the current theme. final Color backgroundColor; - /// The callback that is invoked when the button is tapped or otherwise activated. + /// The callback that is called when the button is tapped or otherwise activated. /// /// If this is set to null, the button will be disabled. final VoidCallback onPressed; diff --git a/packages/flutter/lib/src/material/icon_button.dart b/packages/flutter/lib/src/material/icon_button.dart index 40faaa1194..f202e5c737 100644 --- a/packages/flutter/lib/src/material/icon_button.dart +++ b/packages/flutter/lib/src/material/icon_button.dart @@ -76,7 +76,7 @@ class IconButton extends StatelessWidget { /// See also [color]. final Color disabledColor; - /// The callback that is invoked when the button is tapped or otherwise activated. + /// The callback that is called when the button is tapped or otherwise activated. /// /// If this is set to null, the button will be disabled. final VoidCallback onPressed; diff --git a/packages/flutter/lib/src/material/material.dart b/packages/flutter/lib/src/material/material.dart index ea04cd8c9d..1ba18aa87e 100644 --- a/packages/flutter/lib/src/material/material.dart +++ b/packages/flutter/lib/src/material/material.dart @@ -110,7 +110,7 @@ abstract class MaterialInkController { /// The ink splash is clipped only to the edges of the [Material]. /// This is the default. /// - /// When the splash is removed, onRemoved will be invoked. + /// When the splash is removed, onRemoved will be called. InkSplash splashAt({ RenderBox referenceBox, Point position, diff --git a/packages/flutter/lib/src/material/raised_button.dart b/packages/flutter/lib/src/material/raised_button.dart index 0c40129c16..13a5888c8f 100644 --- a/packages/flutter/lib/src/material/raised_button.dart +++ b/packages/flutter/lib/src/material/raised_button.dart @@ -48,7 +48,7 @@ class RaisedButton extends StatelessWidget { this.child }) : super(key: key); - /// The callback that is invoked when the button is tapped or otherwise activated. + /// The callback that is called when the button is tapped or otherwise activated. /// /// If this is set to null, the button will be disabled. final VoidCallback onPressed; diff --git a/packages/flutter/lib/src/material/snack_bar.dart b/packages/flutter/lib/src/material/snack_bar.dart index 73097f9198..8fb24fef66 100644 --- a/packages/flutter/lib/src/material/snack_bar.dart +++ b/packages/flutter/lib/src/material/snack_bar.dart @@ -54,9 +54,9 @@ class SnackBarAction extends StatefulWidget { /// The button label. final String label; - /// The callback to be invoked when the button is pressed. Must not be null. + /// The callback to be called when the button is pressed. Must not be null. /// - /// This callback will be invoked at most once each time this action is + /// This callback will be called at most once each time this action is /// displayed in a [SnackBar]. final VoidCallback onPressed; diff --git a/packages/flutter/lib/src/rendering/binding.dart b/packages/flutter/lib/src/rendering/binding.dart index 0cad857740..74d6050406 100644 --- a/packages/flutter/lib/src/rendering/binding.dart +++ b/packages/flutter/lib/src/rendering/binding.dart @@ -104,7 +104,7 @@ abstract class RendererBinding extends BindingBase implements SchedulerBinding, _renderView.attach(pipelineOwner); } - /// Invoked when the system metrics change. + /// Called when the system metrics change. /// /// See [ui.window.onMetricsChanged]. void handleMetricsChanged() { diff --git a/packages/flutter/lib/src/rendering/box.dart b/packages/flutter/lib/src/rendering/box.dart index d18ec45e78..59289a94de 100644 --- a/packages/flutter/lib/src/rendering/box.dart +++ b/packages/flutter/lib/src/rendering/box.dart @@ -854,7 +854,7 @@ abstract class RenderBox extends RenderObject { if (needsLayout) { throw new FlutterError( 'Cannot hit test a dirty render box.\n' - 'The hitTest() method was invoked on this RenderBox:\n' + 'The hitTest() method was called on this RenderBox:\n' ' $this\n' 'Unfortunately, since this object has been marked as needing layout, its geometry is not known at this time. ' 'This means it cannot be accurately hit-tested. Make sure to only mark nodes as needing layout during a pipeline ' @@ -866,7 +866,7 @@ abstract class RenderBox extends RenderObject { if (!hasSize) { throw new FlutterError( 'Cannot hit test a render box with no size.\n' - 'The hitTest() method was invoked on this RenderBox:\n' + 'The hitTest() method was called on this RenderBox:\n' ' $this\n' 'Although this node is not marked as needing layout, its size is not set. A RenderBox object must have an ' 'explicit size before it can be hit-tested. Make sure that the RenderBox in question sets its size during layout.' diff --git a/packages/flutter/lib/src/rendering/custom_layout.dart b/packages/flutter/lib/src/rendering/custom_layout.dart index c2389e55f9..2b88b3815a 100644 --- a/packages/flutter/lib/src/rendering/custom_layout.dart +++ b/packages/flutter/lib/src/rendering/custom_layout.dart @@ -40,7 +40,7 @@ abstract class MultiChildLayoutDelegate { /// /// Call this from your [performLayout] function to lay out each /// child. Every child must be laid out using this function exactly - /// once each time the [performLayout] function is invoked. + /// once each time the [performLayout] function is called. Size layoutChild(Object childId, BoxConstraints constraints) { final RenderBox child = _idToChild[childId]; assert(() { diff --git a/packages/flutter/lib/src/rendering/object.dart b/packages/flutter/lib/src/rendering/object.dart index 6f8cceda2b..7942839870 100644 --- a/packages/flutter/lib/src/rendering/object.dart +++ b/packages/flutter/lib/src/rendering/object.dart @@ -1346,7 +1346,7 @@ abstract class RenderObject extends AbstractNode implements HitTestTarget { VoidCallback _performLayout = _doNothing; /// Allows this render object to mutate its child list during layout and - /// invokes callback. + /// calls callback. void invokeLayoutCallback(LayoutCallback callback) { assert(_debugMutationsLocked); assert(_debugDoingThisLayout); @@ -1374,7 +1374,7 @@ abstract class RenderObject extends AbstractNode implements HitTestTarget { // N = newAngle-oldAngle // ...but the rendering is expected to remain the same, pixel for // pixel, on the output device. Then, the layout() method or - // equivalent will be invoked. + // equivalent will be called. // PAINTING diff --git a/packages/flutter/lib/src/rendering/proxy_box.dart b/packages/flutter/lib/src/rendering/proxy_box.dart index e82ae8213d..221bf4664f 100644 --- a/packages/flutter/lib/src/rendering/proxy_box.dart +++ b/packages/flutter/lib/src/rendering/proxy_box.dart @@ -1388,7 +1388,7 @@ class RenderFractionalTranslation extends RenderProxyBox { /// this animation and repaint whenever the animation ticks, avoiding both the /// build and layout phases of the pipeline. /// -/// The [hitTest] method is invoked when the user interacts with the underlying +/// The [hitTest] method is called when the user interacts with the underlying /// render object, to determine if the user hit the object or missed it. abstract class CustomPainter { /// Creates a custom painter. @@ -1439,9 +1439,9 @@ abstract class CustomPainter { /// /// If the method returns `false`, then the paint call might be optimized away. /// - /// It's possible that the [paint] method will get invoked even if + /// It's possible that the [paint] method will get called even if /// [shouldRepaint] returns `false` (e.g. if an ancestor or descendant needed to - /// be repainted). It's also possible that the [paint] method will get invoked + /// be repainted). It's also possible that the [paint] method will get called /// without [shouldRepaint] being called at all (e.g. if the box changes /// size). /// @@ -1489,7 +1489,7 @@ class RenderCustomPaint extends RenderProxyBox { /// The background custom paint delegate. /// - /// This painter, if non-null, is invoked to paint behind the children. + /// This painter, if non-null, is called to paint behind the children. CustomPainter get painter => _painter; CustomPainter _painter; /// Set a new background custom paint delegate. @@ -1497,11 +1497,11 @@ class RenderCustomPaint extends RenderProxyBox { /// If the new delegate is the same as the previous one, this does nothing. /// /// If the new delegate is the same class as the previous one, then the new - /// delegate has its [CustomPainter.shouldRepaint] invoked; if the result is - /// `true`, then the delegate will be invoked. + /// delegate has its [CustomPainter.shouldRepaint] called; if the result is + /// `true`, then the delegate will be called. /// /// If the new delegate is a different class than the previous one, then the - /// delegate will be invoked. + /// delegate will be called. /// /// If the new value is null, then there is no background custom painter. set painter (CustomPainter newPainter) { @@ -1514,7 +1514,7 @@ class RenderCustomPaint extends RenderProxyBox { /// The foreground custom paint delegate. /// - /// This painter, if non-null, is invoked to paint in front of the children. + /// This painter, if non-null, is called to paint in front of the children. CustomPainter get foregroundPainter => _foregroundPainter; CustomPainter _foregroundPainter; /// Set a new foreground custom paint delegate. @@ -1522,11 +1522,11 @@ class RenderCustomPaint extends RenderProxyBox { /// If the new delegate is the same as the previous one, this does nothing. /// /// If the new delegate is the same class as the previous one, then the new - /// delegate has its [CustomPainter.shouldRepaint] invoked; if the result is - /// `true`, then the delegate will be invoked. + /// delegate has its [CustomPainter.shouldRepaint] called; if the result is + /// `true`, then the delegate will be called. /// /// If the new delegate is a different class than the previous one, then the - /// delegate will be invoked. + /// delegate will be called. /// /// If the new value is null, then there is no foreground custom painter. set foregroundPainter (CustomPainter newPainter) { @@ -1633,7 +1633,7 @@ typedef void PointerMoveEventListener(PointerMoveEvent event); typedef void PointerUpEventListener(PointerUpEvent event); typedef void PointerCancelEventListener(PointerCancelEvent event); -/// Invokes the callbacks in response to pointer events. +/// Calls the callbacks in response to pointer events. class RenderPointerListener extends RenderProxyBoxWithHitTestBehavior { RenderPointerListener({ this.onPointerDown, diff --git a/packages/flutter/lib/src/rendering/semantics.dart b/packages/flutter/lib/src/rendering/semantics.dart index d6b91e047f..7fc5697bf7 100644 --- a/packages/flutter/lib/src/rendering/semantics.dart +++ b/packages/flutter/lib/src/rendering/semantics.dart @@ -14,7 +14,7 @@ import 'node.dart'; /// The type of function returned by [RenderObject.getSemanticAnnotators()]. /// -/// These callbacks are invoked with the [SemanticsNode] object that +/// These callbacks are called with the [SemanticsNode] object that /// corresponds to the [RenderObject]. (One [SemanticsNode] can /// correspond to multiple [RenderObject] objects.) /// diff --git a/packages/flutter/lib/src/scheduler/binding.dart b/packages/flutter/lib/src/scheduler/binding.dart index 13ea56ed59..ca5f2dcc3c 100644 --- a/packages/flutter/lib/src/scheduler/binding.dart +++ b/packages/flutter/lib/src/scheduler/binding.dart @@ -26,7 +26,7 @@ double timeDilation = 1.0; /// common time base. typedef void FrameCallback(Duration timeStamp); -/// Signature for the [SchedulerBinding.schedulingStrategy] callback. Invoked +/// Signature for the [SchedulerBinding.schedulingStrategy] callback. Called /// whenever the system needs to decide whether a task at a given /// priority needs to be run. /// @@ -142,7 +142,7 @@ abstract class SchedulerBinding extends BindingBase { _hasRequestedAnEventLoopCallback = true; } - /// Invoked by the system when there is time to run tasks. + /// Called by the system when there is time to run tasks. void handleEventLoopCallback() { _hasRequestedAnEventLoopCallback = false; _runTasks(); @@ -177,7 +177,7 @@ abstract class SchedulerBinding extends BindingBase { /// The current number of transient frame callbacks scheduled. /// /// This is reset to zero just before all the currently scheduled - /// transient callbacks are invoked, at the start of a frame. + /// transient callbacks are called, at the start of a frame. /// /// This number is primarily exposed so that tests can verify that /// there are no unexpected transient callbacks still registered @@ -197,7 +197,7 @@ abstract class SchedulerBinding extends BindingBase { /// the stack trace that is stored for this callback is the original stack /// trace for when the callback was _first_ registered, rather than the stack /// trace for when the callback is reregistered. This makes it easier to track - /// down the original reason that a particular callback was invoked. If + /// down the original reason that a particular callback was called. If /// `rescheduling` is true, the call must be in the context of a frame /// callback. /// @@ -216,7 +216,7 @@ abstract class SchedulerBinding extends BindingBase { /// These callbacks are executed in the order in which they have /// been added. /// - /// Callbacks registered with this method will not be invoked until + /// Callbacks registered with this method will not be called until /// a frame is requested. To register a callback and ensure that a /// frame is immediately scheduled, use [scheduleFrameCallback]. /// @@ -228,7 +228,7 @@ abstract class SchedulerBinding extends BindingBase { /// the stack trace that is stored for this callback is the original stack /// trace for when the callback was _first_ registered, rather than the stack /// trace for when the callback is reregistered. This makes it easier to track - /// down the original reason that a particular callback was invoked. If + /// down the original reason that a particular callback was called. If /// `rescheduling` is true, the call must be in the context of a frame /// callback. /// @@ -259,7 +259,7 @@ abstract class SchedulerBinding extends BindingBase { /// This is expected to be called at the end of tests (the /// flutter_test framework does it automatically in normal cases). /// - /// Invoke this method when you expect there to be no transient + /// Call this method when you expect there to be no transient /// callbacks registered, in an assert statement with a message that /// you want printed when a transient callback is registered: /// @@ -305,7 +305,7 @@ abstract class SchedulerBinding extends BindingBase { /// Adds a persistent frame callback. /// - /// Persistent callbacks are invoked after transient + /// Persistent callbacks are called after transient /// (non-persistent) frame callbacks. /// /// Does *not* request a new frame. Conceptually, persistent frame @@ -346,7 +346,7 @@ abstract class SchedulerBinding extends BindingBase { /// If necessary, schedules a new frame by calling /// [ui.window.scheduleFrame]. /// - /// After this is called, the engine will (eventually) invoke + /// After this is called, the engine will (eventually) call /// [handleBeginFrame]. (This call might be delayed, e.g. if the /// device's screen is turned off it will typically be delayed until /// the screen is on and the application is visible.) @@ -409,7 +409,7 @@ abstract class SchedulerBinding extends BindingBase { Timeline.finishSync(); } - // Invokes the given [callback] with [timestamp] as argument. + // Calls the given [callback] with [timestamp] as argument. // // Wraps the callback in a try/catch and forwards any error to // [debugSchedulerExceptionHandler], if set. If not set, then simply prints diff --git a/packages/flutter/lib/src/scheduler/ticker.dart b/packages/flutter/lib/src/scheduler/ticker.dart index ff48b257c2..b122e9f5b6 100644 --- a/packages/flutter/lib/src/scheduler/ticker.dart +++ b/packages/flutter/lib/src/scheduler/ticker.dart @@ -9,7 +9,7 @@ import 'binding.dart'; /// Signature for the [onTick] constructor argument of the [Ticker] class. /// /// The argument is the time that the object had spent enabled so far -/// at the time of the callback being invoked. +/// at the time of the callback being called. typedef void TickerCallback(Duration elapsed); /// Calls its callback once per animation frame. @@ -28,7 +28,7 @@ class Ticker { int _animationId; Duration _startTime; - /// Whether this ticker has scheduled a call to invoke its callback + /// Whether this ticker has scheduled a call to call its callback /// on the next frame. bool get isTicking => _completer != null; diff --git a/packages/flutter/lib/src/services/haptic_feedback.dart b/packages/flutter/lib/src/services/haptic_feedback.dart index b7bdf4d941..d11ef1dc3c 100644 --- a/packages/flutter/lib/src/services/haptic_feedback.dart +++ b/packages/flutter/lib/src/services/haptic_feedback.dart @@ -17,7 +17,7 @@ mojom.HapticFeedbackProxy _initHapticFeedbackProxy() { final mojom.HapticFeedbackProxy _hapticFeedbackProxy = _initHapticFeedbackProxy(); /// Allows access to the haptic feedback interface on the device. This API is -/// intentionally terse since it invokes default platform behavior. It is not +/// intentionally terse since it calls default platform behavior. It is not /// suitable for use if you require more flexible access to device sensors and /// peripherals. class HapticFeedback { diff --git a/packages/flutter/lib/src/services/image_cache.dart b/packages/flutter/lib/src/services/image_cache.dart index a341ea57cd..a9e43931e2 100644 --- a/packages/flutter/lib/src/services/image_cache.dart +++ b/packages/flutter/lib/src/services/image_cache.dart @@ -140,7 +140,7 @@ class ImageCache { /// /// If the given [ImageProvider] has already been used and is still in the /// cache, then the [ImageResource] object is immediately usable and the - /// provider is not invoked. + /// provider is not called. ImageResource loadProvider(ImageProvider provider) { ImageResource result = _cache[provider]; if (result != null) { diff --git a/packages/flutter/lib/src/services/image_resource.dart b/packages/flutter/lib/src/services/image_resource.dart index a59ce81fbf..3f3713919b 100644 --- a/packages/flutter/lib/src/services/image_resource.dart +++ b/packages/flutter/lib/src/services/image_resource.dart @@ -86,7 +86,7 @@ class ImageResource { try { listener(_image); } catch (exception, stack) { - _handleImageError('by a synchronously-invoked image listener', exception, stack); + _handleImageError('by a synchronously-called image listener', exception, stack); } } } diff --git a/packages/flutter/lib/src/widgets/app.dart b/packages/flutter/lib/src/widgets/app.dart index 729cdeb69c..1e9e4b3eab 100644 --- a/packages/flutter/lib/src/widgets/app.dart +++ b/packages/flutter/lib/src/widgets/app.dart @@ -66,7 +66,7 @@ class WidgetsApp extends StatefulWidget { /// named route. final RouteFactory onGenerateRoute; - /// Callback that is invoked when the operating system changes the + /// Callback that is called when the operating system changes the /// current locale. final LocaleChangedCallback onLocaleChanged; diff --git a/packages/flutter/lib/src/widgets/basic.dart b/packages/flutter/lib/src/widgets/basic.dart index 661c869849..170516cd49 100644 --- a/packages/flutter/lib/src/widgets/basic.dart +++ b/packages/flutter/lib/src/widgets/basic.dart @@ -321,7 +321,7 @@ class ClipOval extends SingleChildRenderObjectWidget { /// Clips its child using a path. /// -/// Invokes a callback on a delegate whenever the widget is to be +/// Calls a callback on a delegate whenever the widget is to be /// painted. The callback returns a path and the widget prevents the /// child from painting outside the path. /// @@ -3042,7 +3042,7 @@ class KeyedSubtree extends StatelessWidget { Widget build(BuildContext context) => child; } -/// A platonic widget that invokes a closure to obtain its child widget. +/// A platonic widget that calls a closure to obtain its child widget. class Builder extends StatelessWidget { Builder({ Key key, this.builder }) : super(key: key) { assert(builder != null); @@ -3050,7 +3050,7 @@ class Builder extends StatelessWidget { /// Called to obtain the child widget. /// - /// This function is invoked whenever this widget is included in its parent's + /// This function is called whenever this widget is included in its parent's /// build and the old widget (if any) that it synchronizes with has a distinct /// object identity. Typically the parent's build method will construct /// a new tree of widgets and so a new Builder child will not be [identical] diff --git a/packages/flutter/lib/src/widgets/binding.dart b/packages/flutter/lib/src/widgets/binding.dart index 2d17347cb1..37d21b2749 100644 --- a/packages/flutter/lib/src/widgets/binding.dart +++ b/packages/flutter/lib/src/widgets/binding.dart @@ -110,7 +110,7 @@ abstract class WidgetsBinding extends BindingBase implements GestureBinding, Ren /// observers). bool removeObserver(WidgetsBindingObserver observer) => _observers.remove(observer); - /// Invoked when the system metrics change. + /// Called when the system metrics change. /// /// Notifies all the observers using /// [WidgetsBindingObserver.didChangeMetrics]. @@ -123,7 +123,7 @@ abstract class WidgetsBinding extends BindingBase implements GestureBinding, Ren observer.didChangeMetrics(); } - /// Invoked when the system locale changes. + /// Called when the system locale changes. /// /// Calls [dispatchLocaleChanged] to notify the binding observers. /// @@ -140,7 +140,7 @@ abstract class WidgetsBinding extends BindingBase implements GestureBinding, Ren observer.didChangeLocale(locale); } - /// Invoked when the system pops the current route. + /// Called when the system pops the current route. /// /// This first notifies the binding observers (using /// [WidgetsBindingObserver.didPopRoute]), in registration order, @@ -161,7 +161,7 @@ abstract class WidgetsBinding extends BindingBase implements GestureBinding, Ren activity.finishCurrentActivity(); } - /// Invoked when the application lifecycle state changes. + /// Called when the application lifecycle state changes. /// /// Notifies all the observers using /// [WidgetsBindingObserver.didChangeAppLifecycleState]. diff --git a/packages/flutter/lib/src/widgets/framework.dart b/packages/flutter/lib/src/widgets/framework.dart index 188a819cac..3a34a2f19c 100644 --- a/packages/flutter/lib/src/widgets/framework.dart +++ b/packages/flutter/lib/src/widgets/framework.dart @@ -421,7 +421,7 @@ abstract class State { if (result is Future) { throw new FlutterError( 'setState() callback argument returned a Future.\n' - 'The setState() method on $this was invoked with a closure or method that ' + 'The setState() method on $this was called with a closure or method that ' 'returned a Future. Maybe it is marked as "async".\n' 'Instead of performing asynchronous work inside a call to setState(), first ' 'execute the work (without updating the widget state), and then synchronously ' @@ -717,7 +717,7 @@ class BuildOwner { if (_dirtyElements.contains(element)) { throw new FlutterError( 'scheduleBuildFor() called for a widget for which a build was already scheduled.\n' - 'The method was invoked for the following element:\n' + 'The method was called for the following element:\n' ' $element\n' 'The current dirty list consists of:\n' ' $_dirtyElements\n' @@ -728,7 +728,7 @@ class BuildOwner { if (!element.dirty) { throw new FlutterError( 'scheduleBuildFor() called for a widget that is not marked as dirty.\n' - 'The method was invoked for the following element:\n' + 'The method was called for the following element:\n' ' $element\n' 'This element is not current marked as dirty. Make sure to set the dirty flag before ' 'calling scheduleBuildFor().\n' @@ -1520,7 +1520,7 @@ abstract class ComponentElement extends BuildableElement { rebuild(); } - /// Reinvokes the build() method of the [StatelessWidget] object (for + /// Calls the build() method of the [StatelessWidget] object (for /// stateless widgets) or the [State] object (for stateful widgets) and /// then updates the widget tree. /// diff --git a/packages/flutter/lib/src/widgets/overlay.dart b/packages/flutter/lib/src/widgets/overlay.dart index 8f32679388..38cec134a7 100644 --- a/packages/flutter/lib/src/widgets/overlay.dart +++ b/packages/flutter/lib/src/widgets/overlay.dart @@ -50,7 +50,7 @@ class OverlayEntry { /// This entry will include the widget built by this builder in the overlay at the entry's position. /// - /// To cause this builder to be invoked again, call [markNeedsBuild] on this + /// To cause this builder to be called again, call [markNeedsBuild] on this /// overlay entry. final WidgetBuilder builder; diff --git a/packages/flutter/lib/src/widgets/scrollable.dart b/packages/flutter/lib/src/widgets/scrollable.dart index 1d1e843470..e4eb1c8cd4 100644 --- a/packages/flutter/lib/src/widgets/scrollable.dart +++ b/packages/flutter/lib/src/widgets/scrollable.dart @@ -464,7 +464,7 @@ class ScrollableState extends State { if (endScrollOffset.isNaN) return null; - final double snappedScrollOffset = snapScrollOffset(endScrollOffset); // invokes the config.snapOffsetCallback callback + final double snappedScrollOffset = snapScrollOffset(endScrollOffset); // Calls the config.snapOffsetCallback callback if (!_scrollOffsetIsInBounds(snappedScrollOffset)) return null; diff --git a/packages/flutter_test/lib/src/binding.dart b/packages/flutter_test/lib/src/binding.dart index 5855ee623b..b153150b28 100644 --- a/packages/flutter_test/lib/src/binding.dart +++ b/packages/flutter_test/lib/src/binding.dart @@ -212,7 +212,7 @@ abstract class TestWidgetsFlutterBinding extends BindingBase /// test failures. bool showAppDumpInErrors = false; - /// Invoke the callback inside a [FakeAsync] scope on which [pump] can + /// Call the callback inside a [FakeAsync] scope on which [pump] can /// advance time. /// /// Returns a future which completes when the test has run. diff --git a/packages/flutter_test/lib/src/test_async_utils.dart b/packages/flutter_test/lib/src/test_async_utils.dart index d9b591b3e8..6aad085eee 100644 --- a/packages/flutter_test/lib/src/test_async_utils.dart +++ b/packages/flutter_test/lib/src/test_async_utils.dart @@ -33,7 +33,7 @@ class _AsyncScope { /// ``` /// /// It does this while still allowing nested calls, e.g. so that you can -/// invoke [expect] from inside callbacks. +/// call [expect] from inside callbacks. /// /// You can use this in your own test functions, if you have some asynchronous /// functions that must be used with "await". Wrap the contents of the function @@ -50,7 +50,7 @@ class TestAsyncUtils { static List<_AsyncScope> _scopeStack = <_AsyncScope>[]; - /// Invokes the given callback in a new async scope. The callback argument is + /// Calls the given callback in a new async scope. The callback argument is /// the asynchronous body of the calling method. The calling method is said to /// be "guarded". Nested calls to guarded methods from within the body of this /// one are fine, but calls to other guarded methods from outside the body of @@ -215,7 +215,7 @@ class TestAsyncUtils { if (collidingGuarder.className == null && collidingGuarder.methodName == 'expect') { message.writeln( 'If you are confident that all test APIs are being called using "await", and ' - 'this expect() call is not being invoked at the top level but is itself being ' + 'this expect() call is not being called at the top level but is itself being ' 'called from some sort of callback registered before the ${originalGuarder.methodName} ' 'method was called, then consider using expectSync() instead.' ); diff --git a/packages/flutter_test/test/test_async_utils_test.dart b/packages/flutter_test/test/test_async_utils_test.dart index a9a9bc9d03..1e1d8a4e6e 100644 --- a/packages/flutter_test/test/test_async_utils_test.dart +++ b/packages/flutter_test/test/test_async_utils_test.dart @@ -114,7 +114,7 @@ void main() { real_test.expect(lines[1], matches(r'^The guarded method "testGuard1" from class TestAPI was called from .*test_async_utils_test.dart on line [0-9]+\.$')); real_test.expect(lines[2], matches(r'^Then, the "expect" function was called from .*test_async_utils_test.dart on line [0-9]+\.$')); real_test.expect(lines[3], 'The first method (TestAPI.testGuard1) had not yet finished executing at the time that the second function (expect) was called. Since both are guarded, and the second was not a nested call inside the first, the first must complete its execution before the second can be called. Typically, this is achieved by putting an "await" statement in front of the call to the first.'); - real_test.expect(lines[4], 'If you are confident that all test APIs are being called using "await", and this expect() call is not being invoked at the top level but is itself being called from some sort of callback registered before the testGuard1 method was called, then consider using expectSync() instead.'); + real_test.expect(lines[4], 'If you are confident that all test APIs are being called using "await", and this expect() call is not being called at the top level but is itself being called from some sort of callback registered before the testGuard1 method was called, then consider using expectSync() instead.'); real_test.expect(lines[5], ''); real_test.expect(lines[6], 'When the first method (TestAPI.testGuard1) was called, this was the stack:'); real_test.expect(lines.length, greaterThan(7)); diff --git a/packages/flutter_tools/lib/src/device.dart b/packages/flutter_tools/lib/src/device.dart index fb8a66352d..3528682d36 100644 --- a/packages/flutter_tools/lib/src/device.dart +++ b/packages/flutter_tools/lib/src/device.dart @@ -19,7 +19,7 @@ import 'ios/simulators.dart'; /// A class to get all available devices. class DeviceManager { /// Constructing DeviceManagers is cheap; they only do expensive work if some - /// of their methods are invoked. + /// of their methods are called. DeviceManager() { // Register the known discoverers. _deviceDiscoverers.add(new AndroidDevices());