Fixed large amount of spelling errors (#83744)

This commit is contained in:
Anis Alibegić 2021-06-02 19:14:06 +02:00 committed by GitHub
parent 9a243a1213
commit c99ed373b3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
124 changed files with 223 additions and 220 deletions

View File

@ -23,7 +23,7 @@ void main() {
driver.close();
});
test('inital tree creation', () async {
test('initial tree creation', () async {
// Let app become fully idle.
await Future<void>.delayed(const Duration(seconds: 2));

View File

@ -35,7 +35,7 @@ class BenchDynamicClipOnStaticPicture extends SceneBuilderRecorder {
BenchDynamicClipOnStaticPicture() : super(name: benchmarkName) {
// If the scrollable extent is too small, the benchmark may end up
// scrolling the picture out of the clip area entirely, resulting in
// bogus metric vaules.
// bogus metric values.
const double maxScrollExtent = kTotalSampleCount * kScrollDelta;
const double pictureHeight = kRows * kRowHeight;
if (maxScrollExtent > pictureHeight) {

View File

@ -245,7 +245,7 @@ class TimeseriesVisualization {
final AnnotatedSample sample = _stats.samples[i];
if (sample.isWarmUpValue) {
// Put gray background behing warm-up samples.
// Put gray background behind warm-up samples.
_ctx.fillStyle = 'rgba(200,200,200,1)';
_ctx.fillRect(xOffset, 0, barWidth, _normalized(_maxValueChartRange));
}

View File

@ -2,4 +2,4 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// THE FOLLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.
// THE FOLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.

View File

@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// THE FOLLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.
// THE FOLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.
import 'dart:async';

View File

@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// THE FOLLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.
// THE FOLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.

View File

@ -2,7 +2,7 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
// THE FOLLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.
// THE FOLLOWING FILES WERE GENERATED BY `flutter gen-l10n`.

View File

@ -73,7 +73,7 @@ class Cocoon {
/// Flutter infrastructure's workflow is:
/// 1. Run DeviceLab test, writing results to a known path
/// 2. Request service account token from luci auth (valid for at least 3 minutes)
/// 3. Upload results from (1) to Cocooon
/// 3. Upload results from (1) to Cocoon
Future<void> sendResultsPath(String resultsPath) async {
final File resultFile = fs.file(resultsPath);
final Map<String, dynamic> resultsJson = json.decode(await resultFile.readAsString()) as Map<String, dynamic>;

View File

@ -25,7 +25,7 @@ final Set<String> noRebootForbidList = <String>{
/// The maximum number of test runs before a device must be rebooted.
///
/// This number was chosen arbitrarily.
const int maxiumRuns = 30;
const int maximumRuns = 30;
/// Represents a unit of work performed in the CI environment that can
/// succeed, fail and be retried independently of others.
@ -190,7 +190,7 @@ class _TaskRunner {
} else {
runCount = 0;
}
if (runCount < maxiumRuns) {
if (runCount < maximumRuns) {
rebootFile
..createSync()
..writeAsStringSync((runCount + 1).toString());

View File

@ -466,7 +466,7 @@ TaskFunction createFramePolicyIntegrationTest() {
) as Map<String, dynamic>;
final Map<String, dynamic> fullLiveData = data['fullyLive'] as Map<String, dynamic>;
final Map<String, dynamic> benchmarkLiveData = data['benchmarkLive'] as Map<String, dynamic>;
final Map<String, dynamic> dataFormated = <String, dynamic>{
final Map<String, dynamic> dataFormatted = <String, dynamic>{
'average_delay_fullyLive_millis':
fullLiveData['average_delay_millis'],
'average_delay_benchmarkLive_millis':
@ -478,8 +478,8 @@ TaskFunction createFramePolicyIntegrationTest() {
};
return TaskResult.success(
dataFormated,
benchmarkScoreKeys: dataFormated.keys.toList(),
dataFormatted,
benchmarkScoreKeys: dataFormatted.keys.toList(),
);
});
};

View File

@ -56,7 +56,7 @@ Future<TaskResult> runWebBenchmark({ @required bool useCanvasKit }) async {
if (benchmarkName != benchmarkIterator.current) {
profileData.completeError(Exception(
'Browser returned benchmark results from a wrong benchmark.\n'
'Requested to run bechmark ${benchmarkIterator.current}, but '
'Requested to run benchmark ${benchmarkIterator.current}, but '
'got results for $benchmarkName.',
));
unawaited(server.close());

View File

@ -10,7 +10,7 @@ Future<void> main() async {
const MethodChannel channel = MethodChannel('com.example.abstract_method_smoke_test');
await channel.invokeMethod<void>('show_keyboard');
runApp(const MyApp());
print('Test suceeded');
print('Test succeeded');
}
class MyApp extends StatelessWidget {

View File

@ -13,5 +13,5 @@ void main() {
),
),
);
print('Test suceeded');
print('Test succeeded');
}

View File

@ -78,7 +78,9 @@ public class MainActivity extends FlutterActivity {
result.put("contentDescription", node.getContentDescription());
flags.put("isChecked", node.isChecked());
flags.put("isCheckable", node.isCheckable());
flags.put("isDismissable", node.isDismissable());
// This is not a typo.
// See: https://developer.android.com/reference/android/view/accessibility/AccessibilityNodeInfo#isDismissable()
flags.put("isDismissible", node.isDismissable());
flags.put("isEditable", node.isEditable());
flags.put("isEnabled", node.isEnabled());
flags.put("isFocusable", node.isFocusable());

View File

@ -172,7 +172,7 @@ class AndroidSemanticsAction {
}
}
static const Map<int, AndroidSemanticsAction> _kactionById = <int, AndroidSemanticsAction>{
static const Map<int, AndroidSemanticsAction> _kActionById = <int, AndroidSemanticsAction>{
_kFocusIndex: focus,
_kClearFocusIndex: clearFocus,
_kSelectIndex: select,
@ -211,6 +211,6 @@ class AndroidSemanticsAction {
///
/// Returns `null` if the id is not a known Android accessibility action.
static AndroidSemanticsAction deserialize(int value) {
return _kactionById[value];
return _kActionById[value];
}
}

View File

@ -15,8 +15,8 @@ class BottomAppBarDemo extends StatefulWidget {
State createState() => _BottomAppBarDemoState();
}
// Flutter generally frowns upon abbrevation however this class uses two
// abbrevations extensively: "fab" for floating action button, and "bab"
// Flutter generally frowns upon abbreviation however this class uses two
// abbreviations extensively: "fab" for floating action button, and "bab"
// for bottom application bar.
class _BottomAppBarDemoState extends State<BottomAppBarDemo> {

View File

@ -5,7 +5,7 @@
import 'package:flutter/material.dart';
class GalleryIcons {
// This class is not meant to be instatiated or extended; this constructor
// This class is not meant to be instantiated or extended; this constructor
// prevents instantiation and extension.
GalleryIcons._();

View File

@ -7,7 +7,7 @@ import 'package:flutter/foundation.dart';
import 'package:flutter_gallery/demo_lists.dart';
import 'package:flutter_test/flutter_test.dart';
/// The demos we don't run as part of the integraiton test.
/// The demos we don't run as part of the integration test.
///
/// Demo names are formatted as 'DEMO_NAME@DEMO_CATEGORY' (see
/// `demo_lists.dart` for more examples).

View File

@ -165,7 +165,7 @@ void main([List<String> args = const <String>[]]) {
// Wait for the first frame to be rasterized.
await driver.waitUntilFirstFrameRasterized();
if (withSemantics) {
print('Enabeling semantics...');
print('Enabling semantics...');
await driver.setSemantics(true);
}

View File

@ -22,7 +22,7 @@ static NSString *_kReloadChannelName = @"reload";
return _engine;
}
- (FlutterBasicMessageChannel *)reloadMessabeChannel {
- (FlutterBasicMessageChannel *)reloadMessageChannel {
return _reloadMessageChannel;
}

View File

@ -85,8 +85,8 @@ void main() {
expect(text.data, 'no-enter');
// Focus on a TextFormField.
final Finder textFormFielsFinder = find.byKey(const Key('input2'));
expect(textFormFielsFinder, findsOneWidget);
final Finder textFormFieldsFinder = find.byKey(const Key('input2'));
expect(textFormFieldsFinder, findsOneWidget);
await tester.tap(find.byKey(const Key('input2')));
// // Press Tab. This should trigger `onFieldSubmitted` of TextField.

View File

@ -75,7 +75,7 @@ void main(List<String> arguments) {
// Verify that the Gradlew wrapper exists.
final File gradleWrapper = androidDirectory.childFile('gradlew');
// Generate Gradle wrapper if it doesn't exists.
// This logic is embededed within the Flutter tool.
// This logic is embedded within the Flutter tool.
// To generate the wrapper, build a flavor that doesn't exist.
if (!gradleWrapper.existsSync()) {
Process.runSync(

View File

@ -140,7 +140,7 @@ const Map<String, LogicalKeyboardKey> kWebNumPadMap = <String, LogicalKeyboardKe
};
/// A map of Web KeyboardEvent keys which needs to be decided based on location,
/// typically for numpad kyes and modifier keys. Used to provide different key
/// typically for numpad keys and modifier keys. Used to provide different key
/// objects for keys like KEY_EQUALS and NUMPAD_EQUALS.
const Map<String, List<LogicalKeyboardKey?>> kWebLocationMap = <String, List<LogicalKeyboardKey?>>{
@@@WEB_LOCATION_MAP@@@

View File

@ -41,7 +41,7 @@ ui.Picture paint(ui.Rect paintBounds) {
ui.Scene composite(ui.Picture picture, ui.Rect paintBounds) {
// The device pixel ratio gives an approximate ratio of the size of pixels on
// the device's screen to "normal" sized pixels. We commonly work in logical
// pixels, which are then scalled by the device pixel ratio before being drawn
// pixels, which are then scaled by the device pixel ratio before being drawn
// on the screen.
final double devicePixelRatio = ui.window.devicePixelRatio;

View File

@ -1401,7 +1401,7 @@ class ElasticInOutCurve extends Curve {
/// * [Curve], the interface implemented by the constants available from the
/// [Curves] class.
class Curves {
// This class is not meant to be instatiated or extended; this constructor
// This class is not meant to be instantiated or extended; this constructor
// prevents instantiation and extension.
Curves._();

View File

@ -230,7 +230,7 @@ class _CupertinoDesktopTextSelectionControlsToolbarState extends State<_Cupertin
/// Typically displays buttons for text manipulation, e.g. copying and pasting
/// text.
///
/// Tries to position itself as closesly as possible to [anchor] while remaining
/// Tries to position itself as closely as possible to [anchor] while remaining
/// fully on-screen.
///
/// See also:

View File

@ -890,7 +890,7 @@ class _CupertinoDialogRenderWidget extends RenderObjectWidget {
class _CupertinoDialogRenderElement extends RenderObjectElement {
_CupertinoDialogRenderElement(_CupertinoDialogRenderWidget widget, {this.allowMoveRenderObjectChild = false}) : super(widget);
// Whether to allow overriden method moveRenderObjectChild call or default to super.
// Whether to allow overridden method moveRenderObjectChild call or default to super.
// CupertinoActionSheet should default to [super] but CupertinoAlertDialog not.
final bool allowMoveRenderObjectChild;

View File

@ -66,7 +66,7 @@ enum _CupertinoFormSectionType { base, insetGrouped }
///
/// {@macro flutter.material.Material.clipBehavior}
class CupertinoFormSection extends StatelessWidget {
/// Creates a section that mimicks standard iOS forms.
/// Creates a section that mimics standard iOS forms.
///
/// The base constructor for [CupertinoFormSection] constructs an
/// edge-to-edge style section which includes an iOS-style header,
@ -111,7 +111,7 @@ class CupertinoFormSection extends StatelessWidget {
assert(children.length > 0),
super(key: key);
/// Creates a section that mimicks standard "Inset Grouped" iOS forms.
/// Creates a section that mimics standard "Inset Grouped" iOS forms.
///
/// The [CupertinoFormSection.insetGrouped] constructor creates a round-edged and
/// padded section that is commonly seen in notched-displays like iPhone X and
@ -217,7 +217,7 @@ class CupertinoFormSection extends StatelessWidget {
// Short divider is used between rows.
// The value of the starting inset (15.0) is determined using SwiftUI's Form
// seperators in the iOS 14.2 SDK.
// separators in the iOS 14.2 SDK.
final Widget shortDivider = Container(
margin: const EdgeInsetsDirectional.only(start: 15.0),
color: dividerColor,

View File

@ -433,7 +433,7 @@ class _RenderCupertinoPickerSemantics extends RenderProxyBox {
late FixedExtentScrollController _controller;
set controller(FixedExtentScrollController value) => _updateController(_controller, value);
// This method exists to allow controller to be non-null. It is only called with a null oldValue from construtor.
// This method exists to allow controller to be non-null. It is only called with a null oldValue from constructor.
void _updateController(FixedExtentScrollController? oldValue, FixedExtentScrollController value) {
if (value == oldValue)
return;

View File

@ -993,7 +993,7 @@ class _RenderSegmentedControl<T> extends RenderBox
assert(rightMost > leftMost);
// Ignore the horizontal position and the height of `thumbRect`, and
// calcuates them from `children`.
// calculates them from `children`.
return Rect.fromLTRB(
math.max(thumbRect.left, leftMost - _kThumbInsets.left),
firstChildOffset.dy - _kThumbInsets.top,

View File

@ -2549,7 +2549,7 @@ class FlagsSummary<T> extends DiagnosticsProperty<Map<String, T?>> {
//
// For a non-null value, its description is its key.
//
// For a null value, it is omitted unless `includeEmtpy` is true and
// For a null value, it is omitted unless `includeEmpty` is true and
// [ifEntryNull] contains a corresponding description.
Iterable<String> _formattedValues() sync* {
for (final MapEntry<String, T?> entry in value.entries) {

View File

@ -27,7 +27,7 @@ import '_platform_io.dart'
/// Tests can also create specific platform tests by and adding a `variant:`
/// argument to the test and using a [TargetPlatformVariant].
//
// When adding support for a new platform (e.g. Windows Phone, Rasberry Pi),
// When adding support for a new platform (e.g. Windows Phone, Raspberry Pi),
// first create a new value on the [TargetPlatform] enum, then add a rule for
// selecting that platform here.
//

View File

@ -240,7 +240,7 @@ class PointerEventResampler {
// Add synthetics `move` or `hover` event if position has changed.
// Note: Devices without `hover` events are expected to always have
// `add` and `down` events with the same position and this logic will
// therefor never produce `hover` events.
// therefore never produce `hover` events.
if (position != _position) {
final Offset delta = position - _position;
callback(_toMoveOrHoverEvent(event, position, delta,

View File

@ -333,7 +333,7 @@ class IOSScrollViewFlingVelocityTracker extends VelocityTracker {
@override
VelocityEstimate getVelocityEstimate() {
// The velocity estimated using this expression is an aproximation of the
// The velocity estimated using this expression is an approximation of the
// scroll velocity of an iOS scroll view at the moment the user touch was
// released, not the final velocity of the iOS pan gesture recognizer
// installed on the scroll view would report. Typically in an iOS scroll

View File

@ -639,7 +639,7 @@ class AppBar extends StatefulWidget implements PreferredSizeWidget {
/// value is true.
///
/// This is a temporary property. When setting it to false is no
/// longer considered a breaking change, it will be depreacted and
/// longer considered a breaking change, it will be deprecated and
/// its default value will be changed to false. App developers are
/// encouraged to opt into the new features by setting it to false
/// and using the [foregroundColor] and [systemOverlayStyle]

View File

@ -221,7 +221,7 @@ class _DesktopTextSelectionControlsToolbarState extends State<_DesktopTextSelect
/// Typically displays buttons for text manipulation, e.g. copying and pasting
/// text.
///
/// Tries to position itself as closesly as possible to [anchor] while remaining
/// Tries to position itself as closely as possible to [anchor] while remaining
/// fully on-screen.
///
/// See also:

View File

@ -230,7 +230,7 @@ class Dialog extends StatelessWidget {
/// onPressed: () => showDialog<String>(
/// context: context,
/// builder: (BuildContext context) => AlertDialog(
/// title: const Text('AlertDialog Tilte'),
/// title: const Text('AlertDialog Title'),
/// content: const Text('AlertDialog description'),
/// actions: <Widget>[
/// TextButton(

View File

@ -584,7 +584,7 @@ class _DropdownRoutePage<T> extends StatelessWidget {
// DropdownButton.itemHeight is specified or DropdownButton.itemHeight is null
// and all of the items' intrinsic heights are less than kMinInteractiveDimension.
// Otherwise the initialScrollOffset is just a rough approximation based on
// treating the items as if their heights were all equal to kMinInteractveDimension.
// treating the items as if their heights were all equal to kMinInteractiveDimension.
if (route.scrollController == null) {
final _MenuLimits menuLimits = route.getMenuLimits(buttonRect, constraints.maxHeight, selectedIndex);
route.scrollController = ScrollController(initialScrollOffset: menuLimits.scrollOffset);

View File

@ -781,7 +781,7 @@ class _InkResponseState extends State<_InkResponseStateWidget>
super.didUpdateWidget(oldWidget);
if (_isWidgetEnabled(widget) != _isWidgetEnabled(oldWidget)) {
if (enabled) {
// Don't call wigdet.onHover because many wigets, including the button
// Don't call widget.onHover because many widgets, including the button
// widgets, apply setState to an ancestor context from onHover.
updateHighlight(_HighlightType.hover, value: _hovering, callOnHover: false);
}

View File

@ -623,7 +623,7 @@ class _TabBarScrollController extends ScrollController {
/// {@end-tool}
///
/// {@tool dartpad --template=stateful_widget_material_ticker}
/// [TabBar] can also be implmented by using a [TabController] which provides more options
/// [TabBar] can also be implemented by using a [TabController] which provides more options
/// to control the behavior of the [TabBar] and [TabBarView]. This can be used instead of
/// a [DefaultTabController], demonstrated below.
///

View File

@ -39,7 +39,7 @@ abstract class ClipContext {
///
/// `bounds` is the saveLayer bounds used for [Clip.antiAliasWithSaveLayer].
void clipPathAndPaint(Path path, Clip clipBehavior, Rect bounds, VoidCallback painter) {
_clipAndPaint((bool doAntiAias) => canvas.clipPath(path, doAntiAlias: doAntiAias), clipBehavior, bounds, painter);
_clipAndPaint((bool doAntiAlias) => canvas.clipPath(path, doAntiAlias: doAntiAlias), clipBehavior, bounds, painter);
}
/// Clip [canvas] with [Path] according to `rrect` and then paint. [canvas] is
@ -47,7 +47,7 @@ abstract class ClipContext {
///
/// `bounds` is the saveLayer bounds used for [Clip.antiAliasWithSaveLayer].
void clipRRectAndPaint(RRect rrect, Clip clipBehavior, Rect bounds, VoidCallback painter) {
_clipAndPaint((bool doAntiAias) => canvas.clipRRect(rrect, doAntiAlias: doAntiAias), clipBehavior, bounds, painter);
_clipAndPaint((bool doAntiAlias) => canvas.clipRRect(rrect, doAntiAlias: doAntiAlias), clipBehavior, bounds, painter);
}
/// Clip [canvas] with [Path] according to `rect` and then paint. [canvas] is
@ -55,6 +55,6 @@ abstract class ClipContext {
///
/// `bounds` is the saveLayer bounds used for [Clip.antiAliasWithSaveLayer].
void clipRectAndPaint(Rect rect, Clip clipBehavior, Rect bounds, VoidCallback painter) {
_clipAndPaint((bool doAntiAias) => canvas.clipRect(rect, doAntiAlias: doAntiAias), clipBehavior, bounds, painter);
_clipAndPaint((bool doAntiAlias) => canvas.clipRect(rect, doAntiAlias: doAntiAlias), clipBehavior, bounds, painter);
}
}

View File

@ -369,7 +369,7 @@ class AssetImage extends AssetBundleImageProvider {
// lowest key.
// - If `value` is greater than the highest key, choose the variant with
// the highest key.
// - If the screen has low device pixel ratio, chosse the variant with the
// - If the screen has low device pixel ratio, choose the variant with the
// lowest key higher than `value`.
// - If the screen has high device pixel ratio, choose the variant with the
// key nearest to `value`.

View File

@ -474,7 +474,7 @@ class StrutStyle with Diagnosticable {
final FontStyle? fontStyle;
/// The additional leading to apply to the strut as a multiple of [fontSize],
/// indepdent of [height] and [leadingDistribution].
/// independent of [height] and [leadingDistribution].
///
/// Leading is additional spacing between lines. Half of the leading is added
/// to the top and the other half to the bottom of the line. This differs

View File

@ -1298,7 +1298,7 @@ class RenderEditable extends RenderBox with RelayoutWhenSystemFontsChangeMixin {
);
}
/// Deletes in the foward direction, from the current selection in
/// Deletes in the forward direction, from the current selection in
/// [textSelectionDelegate].
///
/// This method operates on the text/selection contained in
@ -1349,7 +1349,7 @@ class RenderEditable extends RenderBox with RelayoutWhenSystemFontsChangeMixin {
);
}
/// Deletes a word in the foward direction from the current selection.
/// Deletes a word in the forward direction from the current selection.
///
/// If the [selection] is collapsed, deletes a word after the cursor.
///
@ -1398,7 +1398,7 @@ class RenderEditable extends RenderBox with RelayoutWhenSystemFontsChangeMixin {
);
}
/// Deletes a line in the foward direction from the current selection.
/// Deletes a line in the forward direction from the current selection.
///
/// If the [selection] is collapsed, deletes a line after the cursor.
///

View File

@ -279,7 +279,7 @@ class MouseTracker extends ChangeNotifier {
_mouseCursorMixin.handleDeviceCursorUpdate(
details.device,
details.triggeringEvent,
details.nextAnnotations.keys.map((MouseTrackerAnnotation annotaion) => annotaion.cursor),
details.nextAnnotations.keys.map((MouseTrackerAnnotation annotation) => annotation.cursor),
);
}

View File

@ -414,7 +414,7 @@ class RenderUiKitView extends RenderBox {
}
// This recognizer constructs gesture recognizers from a set of gesture recognizer factories
// it was give, adds all of them to a gesture arena team with the _UiKitViewGesturrRecognizer
// it was give, adds all of them to a gesture arena team with the _UiKitViewGestureRecognizer
// as the team captain.
// When the team wins a gesture the recognizer notifies the engine that it should release
// the touch sequence to the embedded UIView.

View File

@ -4283,7 +4283,7 @@ class RenderSemanticsAnnotations extends RenderProxyBox {
markNeedsSemanticsUpdate();
}
/// Adds a semenatics tag to the semantics subtree.
/// Adds a semantics tag to the semantics subtree.
SemanticsTag? get tagForChildren => _tagForChildren;
SemanticsTag? _tagForChildren;
set tagForChildren(SemanticsTag? value) {

View File

@ -2880,7 +2880,7 @@ const Map<String, LogicalKeyboardKey> kWebNumPadMap = <String, LogicalKeyboardKe
};
/// A map of Web KeyboardEvent keys which needs to be decided based on location,
/// typically for numpad kyes and modifier keys. Used to provide different key
/// typically for numpad keys and modifier keys. Used to provide different key
/// objects for keys like KEY_EQUALS and NUMPAD_EQUALS.
const Map<String, List<LogicalKeyboardKey?>> kWebLocationMap = <String, List<LogicalKeyboardKey?>>{
'0': <LogicalKeyboardKey?>[LogicalKeyboardKey.digit0, null, null, LogicalKeyboardKey.numpad0],

View File

@ -131,7 +131,7 @@ class MethodChannel {
/// If the result is null and `missingOk` is true, this returns null. (This is
/// the behaviour of [OptionalMethodChannel.invokeMethod].)
///
/// If the result is null and `missingOk` is false, this throwsa
/// If the result is null and `missingOk` is false, this throws a
/// [MissingPluginException]. (This is the behaviour of
/// [MethodChannel.invokeMethod].)
///

View File

@ -116,7 +116,7 @@ class RawKeyEventDataIos extends RawKeyEventData {
}
// If this key is printable, generate the LogicalKeyboardKey from its
// Unicode value. Control keys such as ESC, CRTL, and SHIFT are not
// Unicode value. Control keys such as ESC, CTRL, and SHIFT are not
// printable. HOME, DEL, arrow keys, and function keys are considered
// modifier function keys, which generate invalid Unicode scalar values.
if (keyLabel.isNotEmpty &&

View File

@ -85,7 +85,7 @@ class RawKeyEventDataMacOs extends RawKeyEventData {
}
// If this key is printable, generate the LogicalKeyboardKey from its
// Unicode value. Control keys such as ESC, CRTL, and SHIFT are not
// Unicode value. Control keys such as ESC, CTRL, and SHIFT are not
// printable. HOME, DEL, arrow keys, and function keys are considered
// modifier function keys, which generate invalid Unicode scalar values.
if (keyLabel.isNotEmpty &&

View File

@ -51,7 +51,7 @@ class SystemNavigator {
/// Selects the multiple-entry history mode.
///
/// On web, this switches the browser history model to one that tracks alll
/// On web, this switches the browser history model to one that tracks all
/// updates to [routeInformationUpdated] to form a history stack. This is the
/// default.
///

View File

@ -391,7 +391,7 @@ class ToolbarOptions {
/// [RenderEditable.selectWord], etc. programmatically.
///
/// {@template flutter.widgets.editableText.showCaretOnScreen}
/// ## Keep the caret visisble when focused
/// ## Keep the caret visible when focused
///
/// When focused, this widget will make attempts to keep the text area and its
/// caret (even when [showCursor] is `false`) visible, on these occasions:
@ -1253,7 +1253,7 @@ class EditableText extends StatefulWidget {
/// #### Autofill UI refuses to show up when I tap on the text field
///
/// Check the device's system settings and make sure autofill is turned on,
/// and there're available credentials stored in the autofill service.
/// and there are available credentials stored in the autofill service.
///
/// * iOS password autofill: Go to Settings -> Password, turn on "Autofill
/// Passwords", and add new passwords for testing by pressing the top right
@ -1271,7 +1271,7 @@ class EditableText extends StatefulWidget {
///
/// * Android autofill: Go to Settings -> System -> Languages & input ->
/// Autofill service. Enable the autofill service of your choice, and make
/// sure there're available credentials associated with your app.
/// sure there are available credentials associated with your app.
///
/// #### I called `TextInput.finishAutofillContext` but the autofill save
/// prompt isn't showing

View File

@ -427,7 +427,7 @@ class _HeroState extends State<Hero> {
_placeholderSize = null;
if (mounted) {
// Tell the widget to rebuild if it's mounted. _paceholderSize has already
// Tell the widget to rebuild if it's mounted. _placeholderSize has already
// been updated.
setState(() {});
}
@ -626,7 +626,7 @@ class _HeroFlight {
}
}
bool _scheduledPerformAnimtationUpdate = false;
bool _scheduledPerformAnimationUpdate = false;
void _handleAnimationUpdate(AnimationStatus status) {
// The animation will not finish until the user lifts their finger, so we
// should suppress the status update if the gesture is in progress, and
@ -636,23 +636,23 @@ class _HeroFlight {
return;
}
if (_scheduledPerformAnimtationUpdate)
if (_scheduledPerformAnimationUpdate)
return;
// The `navigator` must be non-null here, or the first if clause above would
// have returned from this method.
final NavigatorState navigator = manifest.fromRoute.navigator!;
void delayedPerformAnimtationUpdate() {
void delayedPerformAnimationUpdate() {
assert(!navigator.userGestureInProgress);
assert(_scheduledPerformAnimtationUpdate);
_scheduledPerformAnimtationUpdate = false;
navigator.userGestureInProgressNotifier.removeListener(delayedPerformAnimtationUpdate);
assert(_scheduledPerformAnimationUpdate);
_scheduledPerformAnimationUpdate = false;
navigator.userGestureInProgressNotifier.removeListener(delayedPerformAnimationUpdate);
_performAnimationUpdate(_proxyAnimation.status);
}
assert(navigator.userGestureInProgress);
_scheduledPerformAnimtationUpdate = true;
navigator.userGestureInProgressNotifier.addListener(delayedPerformAnimtationUpdate);
_scheduledPerformAnimationUpdate = true;
navigator.userGestureInProgressNotifier.addListener(delayedPerformAnimationUpdate);
}
void onTick() {
@ -705,20 +705,20 @@ class _HeroFlight {
manifest = initialManifest;
final bool shouldIncludeChildInPlacehold;
final bool shouldIncludeChildInPlaceholder;
switch (manifest.type) {
case HeroFlightDirection.pop:
_proxyAnimation.parent = ReverseAnimation(manifest.animation);
shouldIncludeChildInPlacehold = false;
shouldIncludeChildInPlaceholder = false;
break;
case HeroFlightDirection.push:
_proxyAnimation.parent = manifest.animation;
shouldIncludeChildInPlacehold = true;
shouldIncludeChildInPlaceholder = true;
break;
}
heroRectTween = manifest.createHeroRectTween(begin: manifest.fromHeroLocation, end: manifest.toHeroLocation);
manifest.fromHero.startFlight(shouldIncludedChildInPlaceholder: shouldIncludeChildInPlacehold);
manifest.fromHero.startFlight(shouldIncludedChildInPlaceholder: shouldIncludeChildInPlaceholder);
manifest.toHero.startFlight();
manifest.overlay.insert(overlayEntry = OverlayEntry(builder: _buildOverlay));
_proxyAnimation.addListener(onTick);
@ -955,7 +955,7 @@ class HeroController extends NavigatorObserver {
// If the navigator or the overlay was removed before this end-of-frame
// callback was called, then don't actually start a transition, and we don'
// t have to worry about any Hero widget we might have hidden in a previous
// flight, or onging flights.
// flight, or ongoing flights.
if (navigator == null || overlay == null)
return;

View File

@ -548,7 +548,7 @@ class InteractiveViewer extends StatefulWidget {
///
/// At the time this is called, the [TransformationController] will have
/// already been updated to reflect the change caused by the interaction, if
/// the interation caused the matrix to change.
/// the interaction caused the matrix to change.
///
/// {@macro flutter.widgets.InteractiveViewer.onInteractionEnd}
///

View File

@ -420,7 +420,7 @@ class ScrollPhysics {
@override
String toString() {
if (parent == null)
return objectRuntimeType(this, 'ScrollPhsyics');
return objectRuntimeType(this, 'ScrollPhysics');
return '${objectRuntimeType(this, 'ScrollPhysics')} -> $parent';
}
}

View File

@ -750,7 +750,7 @@ class SliverChildListDelegate extends SliverChildDelegate {
///
/// See also:
///
/// * [KeepAlive], which marks whether its chlild widget should be kept alive.
/// * [KeepAlive], which marks whether its child widget should be kept alive.
/// * [SliverChildBuilderDelegate] and [SliverChildListDelegate], slivers
/// which make usr of the keep alive functionality through the
/// `addAutomaticKeepAlives` property.

View File

@ -293,7 +293,7 @@ void main() {
testWidgets(
'When isAlwaysShown is true, '
'must pass a controller or find PrimarySCrollController that is attached to a scroll view',
'must pass a controller or find PrimaryScrollController that is attached to a scroll view',
(WidgetTester tester) async {
final ScrollController controller = ScrollController();
Widget viewWithScroll() {

View File

@ -279,7 +279,7 @@ package:dart-sdk/lib/async/schedule_microtask.dart 52:5
package:dart-sdk/lib/_internal/js_dev_runtime/patch/async_patch.dart 168:15 <fn>''';
const List<StackFrame> webStackTraceFrames = <StackFrame>[
StackFrame(number: -1, className: '<unknown>', method: 'throw_', packageScheme: 'package', package: 'dart-sdk', packagePath: 'lib/_intenral/js_dev_runtime/private/ddc_runtime/errors.dart', line: 196, column: 49, source: 'package:dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 196:49 throw_'),
StackFrame(number: -1, className: '<unknown>', method: 'throw_', packageScheme: 'package', package: 'dart-sdk', packagePath: 'lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart', line: 196, column: 49, source: 'package:dart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 196:49 throw_'),
StackFrame(number: -1, className: '<unknown>', method: 'blah', packageScheme: 'package', package: 'assertions', packagePath: 'main.dart', line: 4, column: 3, source: 'package:assertions/main.dart 4:3 blah'),
StackFrame(number: -1, className: '<unknown>', method: r'main$', packageScheme: 'package', package: 'assertions', packagePath: 'main.dart', line: 8, column: 5, source: r'package:assertions/main.dart 8:5 main$'),
StackFrame(number: -1, className: '<unknown>', method: r'main$', packageScheme: 'package', package: 'assertions', packagePath: 'main_web_entrypoint.dart', line: 9, column: 3, source: r'package:assertions/main_web_entrypoint.dart 9:3 main$'),

View File

@ -687,7 +687,7 @@ void main() {
resampler.stop(result.add);
// All pointer events should have been returned with orignal
// All pointer events should have been returned with original
// time stamps and positions.
expect(result.length, 6);
expect(result[0].timeStamp, const Duration(microseconds: 1000));

View File

@ -1941,7 +1941,7 @@ void main() {
semantics.dispose();
});
testWidgets('SliverAppBar with flexable space has correct semantics order', (WidgetTester tester) async {
testWidgets('SliverAppBar with flexible space has correct semantics order', (WidgetTester tester) async {
// Regression test for https://github.com/flutter/flutter/issues/64922.
final SemanticsTester semantics = SemanticsTester(tester);

View File

@ -35,7 +35,7 @@ void main() {
'koala',
'lemur',
'mouse',
'northern white rhinocerous',
'northern white rhinoceros',
];
const List<User> kOptionsUsers = <User>[
@ -100,7 +100,7 @@ void main() {
expect(find.byType(ListView), findsOneWidget);
list = find.byType(ListView).evaluate().first.widget as ListView;
// 'chameleon', 'elephant', 'goose', 'lemur', 'mouse', and
// 'northern white rhinocerous' are displayed.
// 'northern white rhinoceros' are displayed.
expect(list.semanticChildCount, 6);
});
@ -336,8 +336,8 @@ void main() {
final Finder listFinder = find.byType(ListView);
expect(listFinder, findsNothing);
/// entering `a` returns 9 items(height > `maxOptionsheight`) from the kOptions
/// so height gets restricted to `maxOptionsheight =250`
/// entering `a` returns 9 items(height > `maxOptionsHeight`) from the kOptions
/// so height gets restricted to `maxOptionsHeight =250`
final double nineItemsHeight = await _getDefaultOptionsHeight(tester, 'a');
expect(nineItemsHeight, equals(maxOptionsHeight));

View File

@ -187,7 +187,7 @@ void main() {
testWidgets('Theme shadowColor', (WidgetTester tester) async {
const ColorScheme colorScheme = ColorScheme.light();
const Color shadowColor = Color(0xff000001);
const Color overiddenColor = Color(0xff000002);
const Color overriddenColor = Color(0xff000002);
Widget buildFrame({ Color? overallShadowColor, Color? themeShadowColor, Color? shadowColor }) {
return MaterialApp(
@ -243,12 +243,12 @@ void main() {
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);
await tester.pumpWidget(buildFrame(overallShadowColor: overiddenColor, themeShadowColor: shadowColor));
await tester.pumpWidget(buildFrame(overallShadowColor: overriddenColor, themeShadowColor: shadowColor));
await tester.pumpAndSettle(); // theme animation
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);
await tester.pumpWidget(buildFrame(themeShadowColor: overiddenColor, shadowColor: shadowColor));
await tester.pumpWidget(buildFrame(themeShadowColor: overriddenColor, shadowColor: shadowColor));
await tester.pumpAndSettle(); // theme animation
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);

View File

@ -1048,7 +1048,7 @@ void main() {
expect(feedback.hapticCount, 0);
});
testWidgets('FloatingActionButton.enableFeedback is overriden by FloatingActionButtonThemeData.enableFeedback', (WidgetTester tester) async {
testWidgets('FloatingActionButton.enableFeedback is overridden by FloatingActionButtonThemeData.enableFeedback', (WidgetTester tester) async {
const bool enableFeedbackTheme = false;
const bool enableFeedback = true;
final ThemeData theme = ThemeData(

View File

@ -190,7 +190,7 @@ void main() {
testWidgets('Theme shadowColor', (WidgetTester tester) async {
const ColorScheme colorScheme = ColorScheme.light();
const Color shadowColor = Color(0xff000001);
const Color overiddenColor = Color(0xff000002);
const Color overriddenColor = Color(0xff000002);
Widget buildFrame({ Color? overallShadowColor, Color? themeShadowColor, Color? shadowColor }) {
return MaterialApp(
@ -246,12 +246,12 @@ void main() {
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);
await tester.pumpWidget(buildFrame(overallShadowColor: overiddenColor, themeShadowColor: shadowColor));
await tester.pumpWidget(buildFrame(overallShadowColor: overriddenColor, themeShadowColor: shadowColor));
await tester.pumpAndSettle(); // theme animation
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);
await tester.pumpWidget(buildFrame(themeShadowColor: overiddenColor, shadowColor: shadowColor));
await tester.pumpWidget(buildFrame(themeShadowColor: overriddenColor, shadowColor: shadowColor));
await tester.pumpAndSettle(); // theme animation
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);

View File

@ -322,7 +322,7 @@ void main() {
),
);
// Tap the first tiem
// Tap the first time
await tester.tap(find.text('Actions'));
await tester.pumpAndSettle();
await tester.tap(find.text('First option'));
@ -343,7 +343,7 @@ void main() {
await tester.pumpAndSettle();
expect(menuItemTapCounters, <int>[2, 1]);
// Tap an iteem without onTap
// Tap an item without onTap
await tester.tap(find.text('Actions'));
await tester.pumpAndSettle();
await tester.tap(find.text('Option without onTap'));
@ -413,7 +413,7 @@ void main() {
expect(menuItemTapCounters, <int>[2, 1]);
expect(selected, 'second');
// Tap an iteem without onTap
// Tap an item without onTap
await tester.tap(find.text('Actions'));
await tester.pumpAndSettle();
await tester.tap(find.text('Option without onTap'));
@ -2275,7 +2275,7 @@ void main() {
feedback.dispose();
});
Widget buildFrame({ bool? widgetEnableFeedack, bool? themeEnableFeedback }) {
Widget buildFrame({ bool? widgetEnableFeedback, bool? themeEnableFeedback }) {
return MaterialApp(
home: Scaffold(
body: PopupMenuTheme(
@ -2283,7 +2283,7 @@ void main() {
enableFeedback: themeEnableFeedback,
),
child: PopupMenuButton<int>(
enableFeedback: widgetEnableFeedack,
enableFeedback: widgetEnableFeedback,
child: const Text('Show Menu'),
itemBuilder: (BuildContext context) {
return <PopupMenuItem<int>>[
@ -2304,7 +2304,7 @@ void main() {
expect(feedback.hapticCount, 0);
// PopupMenuButton with enabled feedback.
await tester.pumpWidget(buildFrame(widgetEnableFeedack: true));
await tester.pumpWidget(buildFrame(widgetEnableFeedback: true));
await tester.tap(find.text('Show Menu'));
await tester.pumpAndSettle();
expect(feedback.clickSoundCount, 1);
@ -2313,7 +2313,7 @@ void main() {
await tester.pumpWidget(Container());
// PopupMenuButton with disabled feedback.
await tester.pumpWidget(buildFrame(widgetEnableFeedack: false));
await tester.pumpWidget(buildFrame(widgetEnableFeedback: false));
await tester.tap(find.text('Show Menu'));
await tester.pumpAndSettle();
expect(feedback.clickSoundCount, 1);
@ -2340,7 +2340,7 @@ void main() {
await tester.pumpWidget(Container());
// PopupMenu enableFeedback property overrides PopupMenuButtonTheme.
await tester.pumpWidget(buildFrame(widgetEnableFeedack: false,themeEnableFeedback: true));
await tester.pumpWidget(buildFrame(widgetEnableFeedback: false,themeEnableFeedback: true));
await tester.tap(find.text('Show Menu'));
await tester.pumpAndSettle();
expect(feedback.clickSoundCount, 2);

View File

@ -185,7 +185,7 @@ void main() {
testWidgets('Theme shadowColor', (WidgetTester tester) async {
const ColorScheme colorScheme = ColorScheme.light();
const Color shadowColor = Color(0xff000001);
const Color overiddenColor = Color(0xff000002);
const Color overriddenColor = Color(0xff000002);
Widget buildFrame({ Color? overallShadowColor, Color? themeShadowColor, Color? shadowColor }) {
return MaterialApp(
@ -241,12 +241,12 @@ void main() {
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);
await tester.pumpWidget(buildFrame(overallShadowColor: overiddenColor, themeShadowColor: shadowColor));
await tester.pumpWidget(buildFrame(overallShadowColor: overriddenColor, themeShadowColor: shadowColor));
await tester.pumpAndSettle(); // theme animation
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);
await tester.pumpWidget(buildFrame(themeShadowColor: overiddenColor, shadowColor: shadowColor));
await tester.pumpWidget(buildFrame(themeShadowColor: overriddenColor, shadowColor: shadowColor));
await tester.pumpAndSettle(); // theme animation
material = tester.widget<Material>(buttonMaterialFinder);
expect(material.shadowColor, shadowColor);

View File

@ -2653,7 +2653,7 @@ void main() {
}
const String hintPlaceholder = 'Placeholder';
const String multipleLineText = "Here's a text, which is more than one line, to demostrate the multiple line hint text";
const String multipleLineText = "Here's a text, which is more than one line, to demonstrate the multiple line hint text";
await tester.pumpWidget(builder(null, hintPlaceholder));
RenderBox findHintText(String hint) => tester.renderObject(find.text(hint));

View File

@ -549,7 +549,7 @@ void main() {
});
// Regression test for https://github.com/flutter/flutter/issues/34847.
testWidgets("reset resets the text field's value to empty when intialValue is null", (WidgetTester tester) async {
testWidgets("reset resets the text field's value to empty when initialValue is null", (WidgetTester tester) async {
await tester.pumpWidget(
MaterialApp(
home: Material(

View File

@ -313,11 +313,11 @@ void main() {
expect(parentData.offset.dx, isNot(equals(0.0)));
paddedBox.child = null;
final RenderConstrainedBox constraintedBox = RenderConstrainedBox(
final RenderConstrainedBox constrainedBox = RenderConstrainedBox(
child: coloredBox,
additionalConstraints: const BoxConstraints(),
);
layout(constraintedBox);
layout(constrainedBox);
expect(coloredBox.parentData?.runtimeType, ParentData);
});
@ -379,7 +379,7 @@ void main() {
expect(unconstrained.getMaxIntrinsicWidth(100.0), equals(200.0));
});
group('ConstraintsTransfromBox', () {
group('ConstraintsTransformBox', () {
FlutterErrorDetails? firstErrorDetails;
void exhaustErrors() {
FlutterErrorDetails? next;

View File

@ -93,10 +93,10 @@ void main() {
});
test('should be 5 when offset is 6 times greater than a specific item extent where the division will return more than 13 zero decimals', () {
const double itemExtentSpecificForAProblematicSreenSize = 411.42857142857144;
const double itemExtentSpecificForAProblematicScreenSize = 411.42857142857144;
final int actual = testGetMaxChildIndexForScrollOffset(
itemExtentSpecificForAProblematicSreenSize * 6 + extraValueToHaveRoundingIssues,
itemExtentSpecificForAProblematicSreenSize,
itemExtentSpecificForAProblematicScreenSize * 6 + extraValueToHaveRoundingIssues,
itemExtentSpecificForAProblematicScreenSize,
);
expect(actual, 5);
});

View File

@ -119,7 +119,7 @@ void main() {
expect(manager.updateScheduled, isFalse);
});
test('claim child with exisiting data', () {
test('claim child with existing data', () {
final MockRestorationManager manager = MockRestorationManager();
final Map<String, dynamic> rawData = _createRawDataSet();
final RestorationBucket bucket = RestorationBucket.root(manager: manager, rawData: rawData);
@ -139,7 +139,7 @@ void main() {
expect(manager.updateScheduled, isFalse);
});
test('claim child with no exisiting data', () {
test('claim child with no existing data', () {
final MockRestorationManager manager = MockRestorationManager();
final Map<String, dynamic> rawData = _createRawDataSet();
final RestorationBucket bucket = RestorationBucket.root(manager: manager, rawData: rawData);

View File

@ -35,7 +35,7 @@ void main() {
'koala',
'lemur',
'mouse',
'northern white rhinocerous',
'northern white rhinoceros',
];
const List<User> kOptionsUsers = <User>[
@ -125,7 +125,7 @@ void main() {
expect(lastOptions.elementAt(2), 'goose');
expect(lastOptions.elementAt(3), 'lemur');
expect(lastOptions.elementAt(4), 'mouse');
expect(lastOptions.elementAt(5), 'northern white rhinocerous');
expect(lastOptions.elementAt(5), 'northern white rhinoceros');
});
testWidgets('can filter and select a list of custom User options', (WidgetTester tester) async {

View File

@ -387,7 +387,7 @@ void main() {
expect(mockCanvas.rects, isEmpty);
expect(mockCanvas.paints, isEmpty);
expect(mockContext.children, isEmpty);
expect(mockContext.offets, isEmpty);
expect(mockContext.offsets, isEmpty);
});
testWidgets('ColoredBox - no size, child', (WidgetTester tester) async {
@ -411,7 +411,7 @@ void main() {
expect(mockCanvas.rects, isEmpty);
expect(mockCanvas.paints, isEmpty);
expect(mockContext.children.single, renderSizedBox);
expect(mockContext.offets.single, Offset.zero);
expect(mockContext.offsets.single, Offset.zero);
});
testWidgets('ColoredBox - size, no child', (WidgetTester tester) async {
@ -424,7 +424,7 @@ void main() {
expect(mockCanvas.rects.single, const Rect.fromLTWH(0, 0, 800, 600));
expect(mockCanvas.paints.single.color, colorToPaint);
expect(mockContext.children, isEmpty);
expect(mockContext.offets, isEmpty);
expect(mockContext.offsets, isEmpty);
});
testWidgets('ColoredBox - size, child', (WidgetTester tester) async {
@ -440,7 +440,7 @@ void main() {
expect(mockCanvas.rects.single, const Rect.fromLTWH(0, 0, 800, 600));
expect(mockCanvas.paints.single.color, colorToPaint);
expect(mockContext.children.single, renderSizedBox);
expect(mockContext.offets.single, Offset.zero);
expect(mockContext.offsets.single, Offset.zero);
});
testWidgets('ColoredBox - properties', (WidgetTester tester) async {
@ -666,7 +666,7 @@ class DoesNotHitRenderBox extends Matcher {
class _MockPaintingContext extends Fake implements PaintingContext {
final List<RenderObject> children = <RenderObject>[];
final List<Offset> offets = <Offset>[];
final List<Offset> offsets = <Offset>[];
@override
final _MockCanvas canvas = _MockCanvas();
@ -674,7 +674,7 @@ class _MockPaintingContext extends Fake implements PaintingContext {
@override
void paintChild(RenderObject child, Offset offset) {
children.add(child);
offets.add(offset);
offsets.add(offset);
}
}

View File

@ -3817,7 +3817,7 @@ void main() {
await tester.pump();
expect(renderEditable.text!.children, isNull);
// Everything's just formated the same way now.
// Everything's just formatted the same way now.
expect(renderEditable.text!.text, 'text composing text');
expect(renderEditable.text!.style!.decoration, isNull);
});

View File

@ -2974,7 +2974,7 @@ Future<void> main() async {
navigatorKey.currentState?.pop();
await tester.pump();
controller.jumpTo(1000);
// Starts Hero animation and scroll animation almost simutaneously.
// Starts Hero animation and scroll animation almost simultaneously.
// Scroll to make the Hero invisible.
await tester.pump();
expect(findRenderOpacity()?.opacity, anyOf(isNull, 1.0));

View File

@ -2649,7 +2649,7 @@ void main() {
expect(logs, isEmpty);
expect(controller.dispatchedPointerEvents, isEmpty);
// Test: Transluscent
// Test: Translucent
await tester.pumpWidget(
scaffold(PlatformViewSurface(
controller: controller,

View File

@ -7,7 +7,7 @@ import 'package:flutter/material.dart';
import 'package:flutter_test/flutter_test.dart';
void main() {
testWidgets('Router state restoration without RouteInfomrationProvider', (WidgetTester tester) async {
testWidgets('Router state restoration without RouteInformationProvider', (WidgetTester tester) async {
final UniqueKey router = UniqueKey();
_TestRouterDelegate delegate() => tester.widget<Router<Object?>>(find.byKey(router)).routerDelegate as _TestRouterDelegate;
@ -41,7 +41,7 @@ void main() {
expect(delegate().restoredRoutePaths, <String>['/foo', '/foo']);
});
testWidgets('Router state restoration with RouteInfomrationProvider', (WidgetTester tester) async {
testWidgets('Router state restoration with RouteInformationProvider', (WidgetTester tester) async {
final UniqueKey router = UniqueKey();
_TestRouterDelegate delegate() => tester.widget<Router<Object?>>(find.byKey(router)).routerDelegate as _TestRouterDelegate;
_TestRouteInformationProvider provider() => tester.widget<Router<Object?>>(find.byKey(router)).routeInformationProvider! as _TestRouteInformationProvider;

View File

@ -263,7 +263,7 @@ void main() {
},
onPopRoute: () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
},
@ -332,7 +332,7 @@ void main() {
},
onPopRoute: () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
},
@ -347,7 +347,7 @@ void main() {
result = await outerDispatcher.invokeCallback(SynchronousFuture<bool>(false));
expect(result, isTrue);
await tester.pump();
expect(find.text('popped outter'), findsOneWidget);
expect(find.text('popped outer'), findsOneWidget);
innerDispatcher1.takePriority();
result = false;
@ -466,7 +466,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
),
),
));
// This should work without calling the takePrioirty on the innerDispatcher2
// This should work without calling the takePriority on the innerDispatcher2
// and the innerDispatcher1.
innerDispatcher3.takePriority();
bool result = false;
@ -757,7 +757,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
},
onPopRoute: () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
},
@ -799,7 +799,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
}
..onPopRoute = () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
};
@ -833,7 +833,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
}
..onPopRoute = () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
};
@ -878,7 +878,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
}
..onPopRoute = () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
};
@ -903,7 +903,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
}
..onPopRoute = () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
};
@ -919,7 +919,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
await tester.pump();
await outerDispatcher.invokeCallback(SynchronousFuture<bool>(false));
await tester.pump();
expect(find.text('popped outter'), findsOneWidget);
expect(find.text('popped outer'), findsOneWidget);
});
testWidgets('Nested backButtonListener should take priority', (WidgetTester tester) async {
@ -961,7 +961,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
},
onPopRoute: () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
},
@ -1016,7 +1016,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
},
onPopRoute: () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
},
@ -1065,7 +1065,7 @@ testWidgets('ChildBackButtonDispatcher take priority recursively', (WidgetTester
}
..onPopRoute = () {
provider.value = const RouteInformation(
location: 'popped outter',
location: 'popped outer',
);
return SynchronousFuture<bool>(true);
};

View File

@ -979,7 +979,7 @@ void main() {
expect(find.byType(ModalBarrier), findsNWidgets(1));
});
testWidgets('showGeneralDialog adds non-dismissable barrier when barrierDismissable is false', (WidgetTester tester) async {
testWidgets('showGeneralDialog adds non-dismissible barrier when barrierDismissible is false', (WidgetTester tester) async {
await tester.pumpWidget(MaterialApp(
home: Builder(
builder: (BuildContext context) {

View File

@ -74,7 +74,7 @@ void main() {
expect(find.text('Hendricks'), findsOneWidget);
});
testWidgets('Stops listening to old listenable after chainging listenable', (WidgetTester tester) async {
testWidgets('Stops listening to old listenable after changing listenable', (WidgetTester tester) async {
await tester.pumpWidget(textBuilderUnderTest);
valueListenable.value = 'Gilfoyle';

View File

@ -114,7 +114,7 @@ class CyclicDiagnostic extends DiagnosticableTree {
final String name;
@override
String toStringShort() => '${objectRuntimeType(this, 'CyclicDiagnistic')}-$name';
String toStringShort() => '${objectRuntimeType(this, 'CyclicDiagnostic')}-$name';
// We have to override toString to avoid the toString call itself triggering a
// stack overflow.
@ -1659,6 +1659,7 @@ class _TestWidgetInspectorService extends TestWidgetInspectorService {
expect(alternateChildJson['valueId'], equals(childJson['valueId']));
alternateChildrenJson = (await service.testExtension('getChildrenSummaryTree', <String, String>{'arg': childJson['objectId']! as String, 'objectGroup': group}))! as List<Object?>;
expect(alternateChildrenJson.length , equals(0));
// Tests are failing when this typo is fixed.
expect(childJson['chidlren'], isNull);
}, skip: !WidgetInspectorService.instance.isWidgetCreationTracked()); // Test requires --track-widget-creation flag.

View File

@ -83,9 +83,9 @@ class WaitForAbsent extends CommandWithTarget {
/// A Flutter Driver command that waits until [finder] can be tapped.
class WaitForTappable extends CommandWithTarget {
/// Creates a command that waits for the widget identified by [finder] to
/// be tappable within the [timeout] amiount of time.
/// be tappable within the [timeout] amount of time.
///
/// If [timeout] is not specified, the command defuts to no timeout.
/// If [timeout] is not specified, the command defaults to no timeout.
WaitForTappable(SerializableFinder finder, {Duration? timeout})
: super(finder, timeout: timeout);

View File

@ -101,7 +101,7 @@ class VMServiceFlutterDriver extends FlutterDriver {
future: _waitForRootIsolate(),
timeout: kUnusuallyLongTimeout,
message: isolateNumber == null
? 'The root isolate is taking an unuusally long time to start.'
? 'The root isolate is taking an unusually long time to start.'
: 'Isolate $isolateNumber is taking an unusually long time to start.',
))!;
_log('Isolate found with number: ${isolateRef.number}');

View File

@ -258,7 +258,7 @@ void main() {
});
testWidgets(
"waiting for NoPendingPlatformMessages returns immediately when there're no platform messages", (WidgetTester tester) async {
'waiting for NoPendingPlatformMessages returns immediately when there are no platform messages', (WidgetTester tester) async {
driverExtension
.call(const WaitForCondition(NoPendingPlatformMessages()).serialize())
.then<void>(expectAsync1((Map<String, dynamic> r) {

View File

@ -154,7 +154,7 @@ void main() {
});
expect(log, <String>[
'VMServiceFlutterDriver: Connecting to Flutter application at ',
'VMServiceFlutterDriver: The root isolate is taking an unuusally long time to start.',
'VMServiceFlutterDriver: The root isolate is taking an unusually long time to start.',
]);
});

View File

@ -19,7 +19,7 @@ void loadDateIntlDataIfNotLoaded() {
// TODO(garyq): Add support for scriptCodes. Do not strip scriptCode from string.
// Keeps track of initialized locales. This can only happen if a locale
// with a stripped scriptCode has already been initialzed. The set of
// with a stripped scriptCode has already been initialized. The set of
// initialized locales should be removed when scriptCode stripping is
// removed.
final Set<String> initializedLocales = <String>{};

View File

@ -48,7 +48,7 @@ void main() {
await tester.pumpWidget(Container());
});
testWidgets('Locale without coutryCode', (WidgetTester tester) async {
testWidgets('Locale without countryCode', (WidgetTester tester) async {
// Regression test for https://github.com/flutter/flutter/pull/16782
await tester.pumpWidget(
MaterialApp(

View File

@ -25,7 +25,7 @@ Iterable<Element> collectAllElementsFrom(
/// Provides a recursive, efficient, depth first search of an element tree.
///
/// [Element.visitChildren] does not guarnatee order, but does guarnatee stable
/// [Element.visitChildren] does not guarantee order, but does guarantee stable
/// order. This iterator also guarantees stable order, and iterates in a left
/// to right order:
///

View File

@ -204,7 +204,7 @@ abstract class WebGoldenComparator {
/// When using `flutter test --platform=chrome`, a comparator implemented by
/// [DefaultWebGoldenComparator] is used if no other comparator is specified. It
/// will send a request to the test server, which uses [goldenFileComparator]
/// for golden file compatison.
/// for golden file comparison.
///
/// When using `flutter test --update-goldens`, the [DefaultWebGoldenComparator]
/// updates the files on disk to match the rendering.

View File

@ -45,7 +45,7 @@ class _AsyncScope {
/// });
/// ```
class TestAsyncUtils {
// This class is not meant to be instatiated or extended; this constructor
// This class is not meant to be instantiated or extended; this constructor
// prevents instantiation and extension.
TestAsyncUtils._();
static const String _className = 'TestAsyncUtils';

View File

@ -160,7 +160,7 @@ def flutter_install_ios_engine_pod(ios_application_path = nil)
# Generate a fake podspec to represent the Flutter framework.
# This is only necessary because plugin podspecs contain `s.dependency 'Flutter'`, and if this Podfile
# does not add a `pod 'Flutter'` CocoaPods will try to download it from the CoocaPods trunk.
# does not add a `pod 'Flutter'` CocoaPods will try to download it from the CocoaPods trunk.
File.open(copied_podspec_path, 'w') { |podspec|
podspec.write <<~EOF
#
@ -198,7 +198,7 @@ def flutter_install_macos_engine_pod(mac_application_path = nil)
# Generate a fake podspec to represent the FlutterMacOS framework.
# This is only necessary because plugin podspecs contain `s.dependency 'FlutterMacOS'`, and if this Podfile
# does not add a `pod 'FlutterMacOS'` CocoaPods will try to download it from the CoocaPods trunk.
# does not add a `pod 'FlutterMacOS'` CocoaPods will try to download it from the CocoaPods trunk.
File.open(copied_podspec_path, 'w') { |podspec|
podspec.write <<~EOF
#

View File

@ -183,7 +183,7 @@ class DeferredComponentsGenSnapshotValidator extends DeferredComponentsValidator
/// considered new.
bool checkAgainstLoadingUnitsCache(
List<LoadingUnit> generatedLoadingUnits) {
final List<LoadingUnit> cachedLoadingUnits = _parseLodingUnitsCache(projectDir.childFile(DeferredComponentsValidator.kLoadingUnitsCacheFileName));
final List<LoadingUnit> cachedLoadingUnits = _parseLoadingUnitsCache(projectDir.childFile(DeferredComponentsValidator.kLoadingUnitsCacheFileName));
loadingUnitComparisonResults = <String, Object>{};
final Set<LoadingUnit> unmatchedLoadingUnits = <LoadingUnit>{};
final List<LoadingUnit> newLoadingUnits = <LoadingUnit>[];
@ -215,7 +215,7 @@ class DeferredComponentsGenSnapshotValidator extends DeferredComponentsValidator
return loadingUnitComparisonResults!['match']! as bool;
}
List<LoadingUnit> _parseLodingUnitsCache(File cacheFile) {
List<LoadingUnit> _parseLoadingUnitsCache(File cacheFile) {
final List<LoadingUnit> loadingUnits = <LoadingUnit>[];
inputs.add(cacheFile);
if (!cacheFile.existsSync()) {

View File

@ -68,7 +68,7 @@ enum HostArtifact {
dart2jsSnapshot,
/// The dart snapshot of the dartdev compiler.
dartdevcSnapshot,
/// The dart snpashot of the kernel worker compiler.
/// The dart snapshot of the kernel worker compiler.
kernelWorkerSnapshot,
/// The root of the web implementation of the dart SDK.
flutterWebSdk,

View File

@ -111,7 +111,7 @@ class LoadingUnit {
/// Constructs a [LoadingUnit].
///
/// Loading units must include an [id] and [libraries]. The [path] is only present when
/// parsing the loading unit from a laoding unit manifest produced by gen_snapshot.
/// parsing the loading unit from a loading unit manifest produced by gen_snapshot.
LoadingUnit({
required this.id,
required this.libraries,

View File

@ -363,7 +363,7 @@ class Stdio {
/// Adds [stream] to [stdout].
Future<void> addStdoutStream(Stream<List<int>> stream) => stdout.addStream(stream);
/// Adds [srtream] to [stderr].
/// Adds [stream] to [stderr].
Future<void> addStderrStream(Stream<List<int>> stream) => stderr.addStream(stream);
}

View File

@ -45,7 +45,7 @@ class BuildBundleCommand extends BuildSubCommand {
)
..addOption('asset-dir',
defaultsTo: getAssetBuildDirectory(),
help: 'The output directory for the kernel_blob.bin file, the native snapshet, the assets, etc. '
help: 'The output directory for the kernel_blob.bin file, the native snapshot, the assets, etc. '
'Can be used to redirect the output when driving the Flutter toolchain from another build system.',
)
..addFlag(

View File

@ -28,7 +28,7 @@ import 'custom_device_config.dart';
import 'custom_device_workflow.dart';
import 'custom_devices_config.dart';
/// Replace all ocurrences of `${someName}` with the value found for that
/// Replace all occurrences of `${someName}` with the value found for that
/// name inside replacementValues or additionalReplacementValues.
///
/// The replacement value is first looked for in [replacementValues] and then
@ -80,7 +80,7 @@ class CustomDeviceLogReader extends DeviceLogReader {
/// Add all lines emitted by [lines] to this [CustomDeviceLogReader]s [logLines]
/// stream.
///
/// Similiar to [listenToProcessOutput], [logLines] will not be marked as done
/// Similar to [listenToProcessOutput], [logLines] will not be marked as done
/// when the argument stream is done.
///
/// Useful when you want to combine the contents of multiple log readers.
@ -215,7 +215,7 @@ class CustomDevicePortForwarder extends DevicePortForwarder {
assert(_forwardedPorts.contains(forwardedPort));
// since a forwarded port represents a running process launched with
// the forwardPortCommand, unforwarding is as easy as killing the proces
// the forwardPortCommand, unforwarding is as easy as killing the process
_processManager.killPid(forwardedPort.context.pid);
_forwardedPorts.remove(forwardedPort);
}

View File

@ -293,7 +293,7 @@ const Feature experimentalInvalidationStrategy = Feature(
),
);
/// The feature for enabling the Windows UWP embeding.
/// The feature for enabling the Windows UWP embedding.
const Feature windowsUwpEmbedding = Feature(
name: 'Flutter for Windows UWP',
configSetting: 'enable-windows-uwp-desktop',

View File

@ -185,7 +185,7 @@ class FuchsiaPackageServer {
int get port => _port;
/// Uses [FuchiaPM.newrepo] and [FuchsiaPM.serve] to spin up a new Fuchsia
/// Uses [FuchsiaPM.newrepo] and [FuchsiaPM.serve] to spin up a new Fuchsia
/// package server.
///
/// Returns false if the repo could not be created or the server could not

Some files were not shown because too many files have changed in this diff Show More