Skip to content

Commit 1fd71de

Browse files
authored
Remove superfluous words from comments (#119055)
* Remove superfluous words from comments. * Revert `win32_window.h` Which seems to come from `gallery`
1 parent 0dd63d3 commit 1fd71de

28 files changed

+38
-38
lines changed

packages/flutter/lib/src/cupertino/adaptive_text_selection_toolbar.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -157,15 +157,15 @@ class CupertinoAdaptiveTextSelectionToolbar extends StatelessWidget {
157157
final List<ContextMenuButtonItem>? buttonItems;
158158

159159
/// Returns a List of Widgets generated by turning [buttonItems] into the
160-
/// the default context menu buttons for Cupertino on the current platform.
160+
/// default context menu buttons for Cupertino on the current platform.
161161
///
162162
/// This is useful when building a text selection toolbar with the default
163163
/// button appearance for the given platform, but where the toolbar and/or the
164164
/// button actions and labels may be custom.
165165
///
166166
/// Does not build Material buttons. On non-Apple platforms, Cupertino buttons
167167
/// will still be used, because the Cupertino library does not access the
168-
/// Material library. To get the native-looking buttons on every platform, use
168+
/// Material library. To get the native-looking buttons on every platform,
169169
/// use [AdaptiveTextSelectionToolbar.getAdaptiveButtons] in the Material
170170
/// library.
171171
///

packages/flutter/lib/src/foundation/diagnostics.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2561,7 +2561,7 @@ class DiagnosticsProperty<T> extends DiagnosticsNode {
25612561
/// The [showName], [showSeparator], [style], [missingIfNull], and [level]
25622562
/// arguments must not be null.
25632563
///
2564-
/// The [level] argument is just a suggestion and can be overridden if
2564+
/// The [level] argument is just a suggestion and can be overridden
25652565
/// if something else about the property causes it to have a lower or higher
25662566
/// level. For example, if calling `computeValue` throws an exception, [level]
25672567
/// will always return [DiagnosticLevel.error].

packages/flutter/lib/src/gestures/monodrag.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ abstract class DragGestureRecognizer extends OneSequenceGestureRecognizer {
180180
/// * [allowedButtonsFilter], which decides which button will be allowed.
181181
GestureDragCancelCallback? onCancel;
182182

183-
/// The minimum distance an input pointer drag must have moved to
183+
/// The minimum distance an input pointer drag must have moved
184184
/// to be considered a fling gesture.
185185
///
186186
/// This value is typically compared with the distance traveled along the

packages/flutter/lib/src/material/action_chip.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ import 'theme_data.dart';
2020
/// Action chips can be tapped to trigger an action or show progress and
2121
/// confirmation. For Material 3, a disabled state is supported for Action
2222
/// chips and is specified with [onPressed] being null. For previous versions
23-
/// of Material Design, it is recommended to remove the Action chip from the
23+
/// of Material Design, it is recommended to remove the Action chip from
2424
/// the interface entirely rather than display a disabled chip.
2525
///
2626
/// Action chips are displayed after primary content, such as below a card or

packages/flutter/lib/src/material/adaptive_text_selection_toolbar.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -220,7 +220,7 @@ class AdaptiveTextSelectionToolbar extends StatelessWidget {
220220
}
221221

222222
/// Returns a List of Widgets generated by turning [buttonItems] into the
223-
/// the default context menu buttons for the current platform.
223+
/// default context menu buttons for the current platform.
224224
///
225225
/// This is useful when building a text selection toolbar with the default
226226
/// button appearance for the given platform, but where the toolbar and/or the

packages/flutter/lib/src/material/app_bar.dart

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ class _PreferredAppBarSize extends Size {
129129
///
130130
/// If the app bar's [actions] contains [TextButton]s, they will not
131131
/// be visible if their foreground (text) color is the same as the
132-
/// the app bar's background color.
132+
/// app bar's background color.
133133
///
134134
/// The default app bar [backgroundColor] is the overall theme's
135135
/// [ColorScheme.primary] if the overall theme's brightness is
@@ -591,7 +591,7 @@ class AppBar extends StatefulWidget implements PreferredSizeWidget {
591591
/// See also:
592592
///
593593
/// * [actionsIconTheme], which defines the appearance of icons in
594-
/// in the [actions] list.
594+
/// the [actions] list.
595595
final IconThemeData? iconTheme;
596596

597597
/// {@template flutter.material.appbar.actionsIconTheme}
@@ -746,7 +746,7 @@ class AppBar extends StatefulWidget implements PreferredSizeWidget {
746746
///
747747
/// * [titleTextStyle], which overrides the default text style for the [title].
748748
/// * [DefaultTextStyle], which overrides the default text style for all of the
749-
/// the widgets in a subtree.
749+
/// widgets in a subtree.
750750
final TextStyle? toolbarTextStyle;
751751

752752
/// {@template flutter.material.appbar.titleTextStyle}
@@ -764,7 +764,7 @@ class AppBar extends StatefulWidget implements PreferredSizeWidget {
764764
/// [title], [leading], and [actions] widgets, also known as the
765765
/// AppBar's "toolbar".
766766
/// * [DefaultTextStyle], which overrides the default text style for all of the
767-
/// the widgets in a subtree.
767+
/// widgets in a subtree.
768768
final TextStyle? titleTextStyle;
769769

770770
/// {@template flutter.material.appbar.systemOverlayStyle}

packages/flutter/lib/src/material/checkbox.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ import 'toggleable.dart';
3434
///
3535
/// {@tool dartpad}
3636
/// This example shows how you can override the default theme of
37-
/// of a [Checkbox] with a [MaterialStateProperty].
37+
/// a [Checkbox] with a [MaterialStateProperty].
3838
/// In this example, the checkbox's color will be `Colors.blue` when the [Checkbox]
3939
/// is being pressed, hovered, or focused. Otherwise, the checkbox's color will
4040
/// be `Colors.red`.

packages/flutter/lib/src/material/drawer.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ const Duration _kBaseSettleDuration = Duration(milliseconds: 246);
115115
/// {@end-tool}
116116
///
117117
/// An open drawer may be closed with a swipe to close gesture, pressing the
118-
/// the escape key, by tapping the scrim, or by calling pop route function such as
118+
/// escape key, by tapping the scrim, or by calling pop route function such as
119119
/// [Navigator.pop]. For example a drawer item might close the drawer when tapped:
120120
///
121121
/// ```dart

packages/flutter/lib/src/material/flexible_space_bar.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ class FlexibleSpaceBar extends StatefulWidget {
116116
/// bottom-left or its center.
117117
///
118118
/// Typically this property is used to adjust how far the title is
119-
/// is inset from the bottom-left and it is specified along with
119+
/// inset from the bottom-left and it is specified along with
120120
/// [centerTitle] false.
121121
///
122122
/// By default the value of this property is

packages/flutter/lib/src/material/range_slider.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,7 @@ class RangeSlider extends StatefulWidget {
326326
/// the range slider thumb is hovered or dragged.
327327
///
328328
/// If this property is null, [RangeSlider] will use [activeColor] with
329-
/// with an opacity of 0.12. If null, [SliderThemeData.overlayColor]
329+
/// an opacity of 0.12. If null, [SliderThemeData.overlayColor]
330330
/// will be used, otherwise defaults to [ColorScheme.primary] with
331331
/// an opacity of 0.12.
332332
final MaterialStateProperty<Color?>? overlayColor;

packages/flutter/lib/src/material/slider.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -431,7 +431,7 @@ class Slider extends StatefulWidget {
431431
/// the slider thumb is focused, hovered, or dragged.
432432
///
433433
/// If this property is null, [Slider] will use [activeColor] with
434-
/// with an opacity of 0.12, If null, [SliderThemeData.overlayColor]
434+
/// an opacity of 0.12, If null, [SliderThemeData.overlayColor]
435435
/// will be used.
436436
///
437437
/// If that is also null, If [ThemeData.useMaterial3] is true,

packages/flutter/lib/src/material/snack_bar.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ class SnackBarAction extends StatefulWidget {
9696
/// [SnackBarThemeData.actionTextColor].
9797
///
9898
/// If [textColor] is a [MaterialStateColor], then the text color will be
99-
/// be resolved against the set of [MaterialState]s that the action text
99+
/// resolved against the set of [MaterialState]s that the action text
100100
/// is in, thus allowing for different colors for states such as pressed,
101101
/// hovered and others.
102102
final Color? textColor;
@@ -366,7 +366,7 @@ class SnackBar extends StatefulWidget {
366366
/// inverse surface.
367367
///
368368
/// If [closeIconColor] is a [MaterialStateColor], then the icon color will be
369-
/// be resolved against the set of [MaterialState]s that the action text
369+
/// resolved against the set of [MaterialState]s that the action text
370370
/// is in, thus allowing for different colors for states such as pressed,
371371
/// hovered and others.
372372
final Color? closeIconColor;

packages/flutter/lib/src/material/theme_data.dart

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1145,7 +1145,7 @@ class ThemeData with Diagnosticable {
11451145
/// to determine the current platform for the purpose of emulating the
11461146
/// platform behavior (e.g. scrolling or haptic effects). Widgets and render
11471147
/// objects at lower layers that try to emulate the underlying platform
1148-
/// platform can depend on [defaultTargetPlatform] directly, or may require
1148+
/// can depend on [defaultTargetPlatform] directly, or may require
11491149
/// that the target platform be provided as an argument. The
11501150
/// [dart:io.Platform] object should only be used directly when it's critical
11511151
/// to actually know the current platform, without any overrides possible (for
@@ -1591,7 +1591,7 @@ class ThemeData with Diagnosticable {
15911591
///
15921592
/// Apps should migrate uses of this property to the theme's [colorScheme]
15931593
/// [ColorScheme.secondary] color. In cases where a color is needed that
1594-
/// that contrasts well with the secondary color [ColorScheme.onSecondary]
1594+
/// contrasts well with the secondary color [ColorScheme.onSecondary]
15951595
/// can be used.
15961596
@Deprecated(
15971597
'Use colorScheme.secondary instead. '
@@ -2539,7 +2539,7 @@ class ThemeData with Diagnosticable {
25392539
/// styles.
25402540
///
25412541
/// In the most basic case, [ThemeData]'s `cupertinoOverrideTheme` is null and
2542-
/// and descendant Cupertino widgets' styling is derived from the Material theme.
2542+
/// descendant Cupertino widgets' styling is derived from the Material theme.
25432543
///
25442544
/// To override individual parts of the Material-derived Cupertino styling,
25452545
/// `cupertinoOverrideTheme`'s construction parameters can be used.

packages/flutter/lib/src/painting/box_shadow.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ class BoxShadow extends ui.Shadow {
8080

8181
/// Linearly interpolate between two box shadows.
8282
///
83-
/// If either box shadow is null, this function linearly interpolates from a
83+
/// If either box shadow is null, this function linearly interpolates from
8484
/// a box shadow that matches the other box shadow in color but has a zero
8585
/// offset and a zero blurRadius.
8686
///

packages/flutter/lib/src/painting/gradient.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -468,7 +468,7 @@ class LinearGradient extends Gradient {
468468

469469
/// Linearly interpolate between two [LinearGradient]s.
470470
///
471-
/// If either gradient is null, this function linearly interpolates from a
471+
/// If either gradient is null, this function linearly interpolates from
472472
/// a gradient that matches the other gradient in [begin], [end], [stops] and
473473
/// [tileMode] and with the same [colors] but transparent (using [scale]).
474474
///
@@ -747,7 +747,7 @@ class RadialGradient extends Gradient {
747747

748748
/// Linearly interpolate between two [RadialGradient]s.
749749
///
750-
/// If either gradient is null, this function linearly interpolates from a
750+
/// If either gradient is null, this function linearly interpolates from
751751
/// a gradient that matches the other gradient in [center], [radius], [stops] and
752752
/// [tileMode] and with the same [colors] but transparent (using [scale]).
753753
///

packages/flutter/lib/src/rendering/sliver_multi_box_adaptor.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ class SliverMultiBoxAdaptorParentData extends SliverLogicalParentData with Conta
169169
/// been laid out during that layout pass.
170170
/// * Children cannot be added except during a call to [childManager], and
171171
/// then only if there is no child corresponding to that index (or the child
172-
/// child corresponding to that index was first removed).
172+
/// corresponding to that index was first removed).
173173
///
174174
/// See also:
175175
///

packages/flutter/lib/src/widgets/draggable_scrollable_sheet.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -317,7 +317,7 @@ class DraggableScrollableSheet extends StatefulWidget {
317317
/// The initial fractional value of the parent container's height to use when
318318
/// displaying the widget.
319319
///
320-
/// Rebuilding the sheet with a new [initialChildSize] will only move the
320+
/// Rebuilding the sheet with a new [initialChildSize] will only move
321321
/// the sheet to the new value if the sheet has not yet been dragged since it
322322
/// was first built or since the last call to [DraggableScrollableActuator.reset].
323323
///

packages/flutter/lib/src/widgets/editable_text.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3966,7 +3966,7 @@ class EditableTextState extends State<EditableText> with AutomaticKeepAliveClien
39663966
// `x ∉ getTextBoundaryAt(x)`. In case `caretOffset` points to one such
39673967
// control character, we define that these control characters themselves are
39683968
// still part of the previous line, but also exclude them from the
3969-
// the line boundary range since they're non-printing. IOW, no additional
3969+
// line boundary range since they're non-printing. IOW, no additional
39703970
// processing needed since the LineBoundary class does exactly that.
39713971
return forward
39723972
? TextPosition(offset: textBoundary.getTrailingTextBoundaryAt(caretOffset) ?? _value.text.length, affinity: TextAffinity.upstream)

packages/flutter/lib/src/widgets/localizations.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -318,8 +318,8 @@ class _LocalizationsScope extends InheritedWidget {
318318
/// }
319319
/// ```
320320
///
321-
/// Each delegate can be viewed as a factory for objects that encapsulate a
322-
/// a set of localized resources. These objects are retrieved with
321+
/// Each delegate can be viewed as a factory for objects that encapsulate a set
322+
/// of localized resources. These objects are retrieved with
323323
/// by runtime type with [Localizations.of].
324324
///
325325
/// The [WidgetsApp] class creates a [Localizations] widget so most apps

packages/flutter/lib/src/widgets/performance_overlay.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ class PerformanceOverlay extends LeafRenderObjectWidget {
5959
/// For example, if you want a trace of all pictures that could not be
6060
/// rendered by the rasterizer within the frame boundary (and hence caused
6161
/// jank), specify 1. Specifying 2 will trace all pictures that took more
62-
/// more than 2 frame intervals to render. Adjust this value to only capture
62+
/// than 2 frame intervals to render. Adjust this value to only capture
6363
/// the particularly expensive pictures while skipping the others. Specifying
6464
/// 0 disables all capture.
6565
///

packages/flutter/lib/src/widgets/scroll_physics.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -405,8 +405,8 @@ class ScrollPhysics {
405405
);
406406
}
407407

408-
/// The minimum distance an input pointer drag must have moved to
409-
/// to be considered a scroll fling gesture.
408+
/// The minimum distance an input pointer drag must have moved to be
409+
/// considered a scroll fling gesture.
410410
///
411411
/// This value is typically compared with the distance traveled along the
412412
/// scrolling axis.

packages/flutter/test/material/tabs_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -704,7 +704,7 @@ void main() {
704704
}
705705
// End the fling by reversing direction. This should cause not cause
706706
// a change to the selected tab, everything should just settle back to
707-
// to where it started.
707+
// where it started.
708708
for (int index = 0; index > 50; index += 1) {
709709
await gesture.moveBy(const Offset(10.0, 0.0));
710710
await tester.pump(const Duration(milliseconds: 1));

packages/flutter/test/material/text_field_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11039,7 +11039,7 @@ void main() {
1103911039
expect(
1104011040
tester.getSize(find.byType(TextField)),
1104111041
// When the strut fontSize is larger than a provided TextStyle, the
11042-
// the strut's height takes precedence.
11042+
// strut's height takes precedence.
1104311043
const Size(800, 78),
1104411044
);
1104511045
},

packages/flutter/test/physics/newton_test.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ void main() {
6060
expect(friction.dx(1.0), moreOrLessEquals(endVelocity));
6161

6262
// Same scenario as above except that the velocities are
63-
// are negative.
63+
// negative.
6464
startPosition = 1000.0;
6565
startVelocity = -500.0;
6666
f = FrictionSimulation(0.025, 1000.0, -500.0);

packages/flutter_tools/lib/src/base/utils.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@ List<String> _wrapTextAsLines(String text, {
339339
final int effectiveLength = math.max(columnWidth - start, kMinColumnWidth);
340340
for (final String line in text.split('\n')) {
341341
// If the line is short enough, even with ANSI codes, then we can just add
342-
// add it and move on.
342+
// it and move on.
343343
if (line.length <= effectiveLength || !shouldWrap) {
344344
result.add(line);
345345
continue;

packages/flutter_tools/lib/src/localizations/message_parser.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ class Parser {
335335
parsingStack.addAll(grammarRule.reversed);
336336

337337
// For tree construction, add nodes to the parent until the parent has all
338-
// all the children it is expecting.
338+
// the children it is expecting.
339339
parent.children.add(node);
340340
if (parent.isFull) {
341341
treeTraversalStack.removeLast();

packages/flutter_tools/lib/src/template.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ class Template {
8686
from: templateFiles[entity]!.absolute.path);
8787
if (relativePath.contains(templateExtension)) {
8888
// If '.tmpl' appears anywhere within the path of this entity, it is
89-
// is a candidate for rendering. This catches cases where the folder
89+
// a candidate for rendering. This catches cases where the folder
9090
// itself is a template.
9191
_templateFilePaths[relativePath] = fileSystem.path.absolute(entity.path);
9292
}

packages/flutter_tools/lib/src/test/web_test_compiler.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ class WebTestCompiler {
5252
LanguageVersion languageVersion = LanguageVersion(2, 8);
5353
late final String platformDillName;
5454

55-
// TODO(zanderso): to support autodetect this would need to partition the source code into a
55+
// TODO(zanderso): to support autodetect this would need to partition the source code into
5656
// a sound and unsound set and perform separate compilations
5757
final List<String> extraFrontEndOptions = List<String>.of(buildInfo.extraFrontEndOptions);
5858
if (buildInfo.nullSafetyMode == NullSafetyMode.unsound || buildInfo.nullSafetyMode == NullSafetyMode.autodetect) {

0 commit comments

Comments
 (0)