Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix typos. #3486

Merged
merged 1 commit into from
Nov 2, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/devtools_app/lib/src/debugger/file_search.dart
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ class FileSearchFieldState extends State<FileSearchField>
searchFieldKey: fileSearchFieldKey,
searchFieldEnabled: true,
shouldRequestFocus: true,
keyEventsToPropogate: {LogicalKeyboardKey.escape},
keyEventsToPropagate: {LogicalKeyboardKey.escape},
onSelection: _onSelection,
onClose: _onClose,
label: 'Open',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -995,7 +995,7 @@ abstract class ObjectGroupBase implements Disposable {
}
}

/// Evaluate an expression where `object` referrences the [inspectorRef] or
/// Evaluate an expression where `object` references the [inspectorRef] or
/// [instanceRef] passed in.
///
/// If both [inspectorRef] and [instanceRef] are passed in they are assumed to
Expand Down
2 changes: 1 addition & 1 deletion packages/devtools_app/lib/src/screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ abstract class Screen {
/// Whether to show the console for this screen.
bool showConsole(bool embed) => false;

/// Which keyboard shortcuts shoud be enabled for this screen.
/// Which keyboard shortcuts should be enabled for this screen.
ShortcutsConfiguration buildKeyboardShortcuts(BuildContext context) =>
ShortcutsConfiguration.empty();

Expand Down
24 changes: 12 additions & 12 deletions packages/devtools_app/lib/src/ui/search.dart
Original file line number Diff line number Diff line change
Expand Up @@ -614,7 +614,7 @@ mixin SearchFieldMixin<T extends StatefulWidget> on State<T> {
/// autocomplete overlay should be positioned relative to the input text.
/// [supportClearField] if true clear TextField content if pop-up not visible. If
/// pop-up is visible close the pop-up on first ESCAPE.
/// [keyEventsToPropogate] a set of key events that should be propogated to
/// [keyEventsToPropagate] a set of key events that should be propagated to
/// other handlers
Widget buildAutoCompleteSearchField({
@required AutoCompleteSearchControllerMixin controller,
Expand All @@ -627,7 +627,7 @@ mixin SearchFieldMixin<T extends StatefulWidget> on State<T> {
String label,
OverlayXPositionBuilder overlayXPositionBuilder,
bool supportClearField = false,
Set<LogicalKeyboardKey> keyEventsToPropogate = const {},
Set<LogicalKeyboardKey> keyEventsToPropagate = const {},
VoidCallback onClose,
}) {
_onSelection = onSelection;
Expand All @@ -653,7 +653,7 @@ mixin SearchFieldMixin<T extends StatefulWidget> on State<T> {
onSelection: onSelection,
onHighlightDropdown: onHighlightDropdown,
clearSearchField: clearSearchField,
keyEventsToPropogate: keyEventsToPropogate,
keyEventsToPropagate: keyEventsToPropagate,
supportClearField: supportClearField,
closeHandler: _closeHandler,
);
Expand Down Expand Up @@ -805,7 +805,7 @@ class _AutoCompleteSearchField extends StatelessWidget {
@required this.onSelection,
@required this.onHighlightDropdown,
@required this.clearSearchField,
this.keyEventsToPropogate = const {},
this.keyEventsToPropagate = const {},
this.supportClearField = false,
this.closeHandler,
});
Expand All @@ -817,7 +817,7 @@ class _AutoCompleteSearchField extends StatelessWidget {
final SelectAutoComplete onSelection;
final HighlightAutoComplete onHighlightDropdown;
final ClearSearchField clearSearchField;
final Set<LogicalKeyboardKey> keyEventsToPropogate;
final Set<LogicalKeyboardKey> keyEventsToPropagate;
final bool supportClearField;
final VoidCallback closeHandler;

Expand Down Expand Up @@ -860,7 +860,7 @@ class _AutoCompleteSearchField extends StatelessWidget {
}
return _determineKeyEventResult(
key,
keyEventsToPropogate,
keyEventsToPropagate,
);
} else if (controller.autoCompleteOverlay != null) {
if (key == enter || key == enterMac || key == tab || key == tabMac) {
Expand Down Expand Up @@ -891,18 +891,18 @@ class _AutoCompleteSearchField extends StatelessWidget {
controller.selectTheSearch = true;
controller.search = foundExact;
onSelection(foundExact);
return _determineKeyEventResult(key, keyEventsToPropogate);
return _determineKeyEventResult(key, keyEventsToPropagate);
}
} else if (key == arrowDown || key == arrowUp) {
highlightDropdown(controller, key == arrowDown);
return _determineKeyEventResult(key, keyEventsToPropogate);
return _determineKeyEventResult(key, keyEventsToPropagate);
}
}

// We don't support tabs in the search input. Swallow to prevent a
// change of focus.
if (key == tab || key == tabMac) {
_determineKeyEventResult(key, keyEventsToPropogate);
_determineKeyEventResult(key, keyEventsToPropagate);
}
}

Expand Down Expand Up @@ -930,11 +930,11 @@ class _AutoCompleteSearchField extends StatelessWidget {

KeyEventResult _determineKeyEventResult(
int keyEventId,
Set<LogicalKeyboardKey> keyEventsToPropogate,
Set<LogicalKeyboardKey> keyEventsToPropagate,
) {
final shouldPropogateKeyEvent = keyEventsToPropogate
final shouldPropagateKeyEvent = keyEventsToPropagate
.any((key) => key.keyId & LogicalKeyboardKey.valueMask == keyEventId);
return shouldPropogateKeyEvent
return shouldPropagateKeyEvent
? KeyEventResult.ignored
: KeyEventResult.handled;
}
Expand Down