[gen_keycodes] Mark generated file names with infix `.g.` (#106142)

diff --git a/dev/tools/gen_keycodes/README.md b/dev/tools/gen_keycodes/README.md
index 5e20091..f9ff1ad 100644
--- a/dev/tools/gen_keycodes/README.md
+++ b/dev/tools/gen_keycodes/README.md
@@ -5,8 +5,8 @@
 
 It generates multiple files across Flutter. For framework, it generates
 
-* [`keyboard_key.dart`](../../../packages/flutter/lib/src/services/keyboard_key.dart), which contains the definition and list of logical keys and physical keys; and
-* [`keyboard_maps.dart`](../../../packages/flutter/lib/src/services/keyboard_maps.dart), which contains platform-specific immutable maps used for the `RawKeyboard` API.
+* [`keyboard_key.g.dart`](../../../packages/flutter/lib/src/services/keyboard_key.g.dart), which contains the definition and list of logical keys and physical keys; and
+* [`keyboard_maps.g.dart`](../../../packages/flutter/lib/src/services/keyboard_maps.g.dart), which contains platform-specific immutable maps used for the `RawKeyboard` API.
 
 For engine, it generates one key mapping file for each platform, as well as some
 files for testing purposes.
@@ -14,9 +14,9 @@
 It draws information from various source bases, including online
 repositories, and manual mapping in the `data` subdirectory. It incorporates
 this information into a giant list of physical keys
-([`physical_key_data.json`](data/physical_key_data.json)),
+([`physical_key_data.g.json`](data/physical_key_data.g.json)),
 and another for logical keys
-([`logical_key_data.json`](data/logical_key_data.json)).
+([`logical_key_data.g.json`](data/logical_key_data.g.json)).
 The two files are checked in, and can be used as the data source next time so that
 output files can be generated without the Internet.
 
@@ -35,7 +35,7 @@
 /PATH/TO/ROOT/bin/gen_keycodes --collect
 ```
 
-This will generate `physical_key_data.json` and `logical_key_data.json`. These
+This will generate `physical_key_data.g.json` and `logical_key_data.g.json`. These
 files should be checked in.
 
 By default this tool assumes that the gclient directory for flutter/engine
@@ -121,7 +121,7 @@
   platforms managed by Flutter will start to send the new value, making it a
   breaking change. Therefore, when handling an unrecognized key on a platform
   managed by Flutter, it is recommended to file a new issue to add this value
-  to `keyboard_key.dart` instead of using the platform-plane value. However,
+  to `keyboard_key.g.dart` instead of using the platform-plane value. However,
   for a custom platform (see below), since the platform author has full control
   over key mapping, such change will not cause breakage and it is recommended
   to use the platform-plane value to avoid adding platform-exclusive values
diff --git a/dev/tools/gen_keycodes/bin/gen_keycodes.dart b/dev/tools/gen_keycodes/bin/gen_keycodes.dart
index 156de14..dd04a70 100644
--- a/dev/tools/gen_keycodes/bin/gen_keycodes.dart
+++ b/dev/tools/gen_keycodes/bin/gen_keycodes.dart
@@ -108,7 +108,7 @@
   );
   argParser.addOption(
     'physical-data',
-    defaultsTo: path.join(dataRoot, 'physical_key_data.json'),
+    defaultsTo: path.join(dataRoot, 'physical_key_data.g.json'),
     help: 'The path to where the physical key data file should be written when '
         'collected, and read from when generating output code. If --physical-data is '
         'not specified, the output will be written to/read from the current '
@@ -117,7 +117,7 @@
   );
   argParser.addOption(
     'logical-data',
-    defaultsTo: path.join(dataRoot, 'logical_key_data.json'),
+    defaultsTo: path.join(dataRoot, 'logical_key_data.g.json'),
     help: 'The path to where the logical key data file should be written when '
         'collected, and read from when generating output code. If --logical-data is '
         'not specified, the output will be written to/read from the current '
@@ -126,16 +126,16 @@
   );
   argParser.addOption(
     'code',
-    defaultsTo: path.join(flutterRoot.path, 'packages', 'flutter', 'lib', 'src', 'services', 'keyboard_key.dart'),
-    help: 'The path to where the output "keyboard_key.dart" file should be '
+    defaultsTo: path.join(flutterRoot.path, 'packages', 'flutter', 'lib', 'src', 'services', 'keyboard_key.g.dart'),
+    help: 'The path to where the output "keyboard_key.g.dart" file should be '
         'written. If --code is not specified, the output will be written to the '
         'correct directory in the flutter tree. If the output directory does not '
         'exist, it, and the path to it, will be created.',
   );
   argParser.addOption(
     'maps',
-    defaultsTo: path.join(flutterRoot.path, 'packages', 'flutter', 'lib', 'src', 'services', 'keyboard_maps.dart'),
-    help: 'The path to where the output "keyboard_maps.dart" file should be '
+    defaultsTo: path.join(flutterRoot.path, 'packages', 'flutter', 'lib', 'src', 'services', 'keyboard_maps.g.dart'),
+    help: 'The path to where the output "keyboard_maps.g.dart" file should be '
       'written. If --maps is not specified, the output will be written to the '
       'correct directory in the flutter tree. If the output directory does not '
       'exist, it, and the path to it, will be created.',
@@ -145,7 +145,7 @@
     negatable: false,
     help: 'If this flag is set, then collect and parse header files from '
         'Chromium and Android instead of reading pre-parsed data from '
-        '"physical_key_data.json" and "logical_key_data.json", and then '
+        '"physical_key_data.g.json" and "logical_key_data.g.json", and then '
         'update these files with the fresh data.',
   );
   argParser.addFlag(
@@ -226,7 +226,7 @@
       KeyboardMapsCodeGenerator(physicalData, logicalData));
   await generate('engine utils',
       path.join(PlatformCodeGenerator.engineRoot,
-          'shell', 'platform', 'embedder', 'test_utils', 'key_codes.h'),
+          'shell', 'platform', 'embedder', 'test_utils', 'key_codes.g.h'),
       KeyCodesCcGenerator(physicalData, logicalData));
   await generate('android utils',
       path.join(PlatformCodeGenerator.engineRoot, 'shell', 'platform',
diff --git a/dev/tools/gen_keycodes/data/README.md b/dev/tools/gen_keycodes/data/README.md
index 80ddefa..d4542a0 100644
--- a/dev/tools/gen_keycodes/data/README.md
+++ b/dev/tools/gen_keycodes/data/README.md
@@ -4,8 +4,8 @@
 
 | File name | Explanation |
 | ---- | ---- |
-| [`physical_key_data.json`](physical_key_data.json) | Contains the merged physical key data from all the other sources. This file is regenerated if "--collect" is specified for the gen_keycodes script, or used as a source otherwise. |
-| [`logical_key_data.json`](logical_key_data.json) | Contains the merged logical key data from all the other sources. This file is regenerated if "--collect" is specified for the gen_keycodes script, or used as a source otherwise. |
+| [`physical_key_data.g.json`](physical_key_data.g.json) | Contains the merged physical key data from all the other sources. This file is regenerated if "--collect" is specified for the gen_keycodes script, or used as a source otherwise. |
+| [`logical_key_data.g.json`](logical_key_data.g.json) | Contains the merged logical key data from all the other sources. This file is regenerated if "--collect" is specified for the gen_keycodes script, or used as a source otherwise. |
 | [`supplemental_hid_codes.inc`](supplemental_hid_codes.inc) | A supplementary HID list on top of Chromium's list of HID codes for extra physical keys. Certain entries may also overwrite Chromium's corresponding entries. |
 | [`supplemental_key_data.inc`](supplemental_key_data.inc) | A supplementary key list on top of Chromium's list of keys for extra logical keys.|
 | [`chromium_modifiers.json`](chromium_modifiers.json) | Maps the web's `key` for modifier keys to the names of the logical keys for these keys' left and right variations.This is used when generating logical keys to provide independent values for sided logical keys. Web uses the same `key` for modifier keys of different sides, but Flutter's logical key model treats them as different keys.|
@@ -17,8 +17,8 @@
 
 | File name | Explanation |
 | ---- | ---- |
-| [`keyboard_key.tmpl`](keyboard_key.tmpl) | The template for `keyboard_key.dart`. |
-| [`keyboard_maps.tmpl`](keyboard_maps.tmpl) | The template for `keyboard_maps.dart`. |
+| [`keyboard_key.tmpl`](keyboard_key.tmpl) | The template for `keyboard_key.g.dart`. |
+| [`keyboard_maps.tmpl`](keyboard_maps.tmpl) | The template for `keyboard_maps.g.dart`. |
 
 
 ### Android
diff --git a/dev/tools/gen_keycodes/data/keyboard_maps.tmpl b/dev/tools/gen_keycodes/data/keyboard_maps.tmpl
index 8a80093..36e4c02 100644
--- a/dev/tools/gen_keycodes/data/keyboard_maps.tmpl
+++ b/dev/tools/gen_keycodes/data/keyboard_maps.tmpl
@@ -9,9 +9,9 @@
 // Edit the template dev/tools/gen_keycodes/data/keyboard_maps.tmpl instead.
 // See dev/tools/gen_keycodes/README.md for more information.
 
-import 'keyboard_key.dart';
+import 'keyboard_key.g.dart';
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 
 /// Maps Android-specific key codes to the matching [LogicalKeyboardKey].
 const Map<int, LogicalKeyboardKey> kAndroidToLogicalKey = <int, LogicalKeyboardKey>{
diff --git a/dev/tools/gen_keycodes/data/logical_key_data.json b/dev/tools/gen_keycodes/data/logical_key_data.g.json
similarity index 100%
rename from dev/tools/gen_keycodes/data/logical_key_data.json
rename to dev/tools/gen_keycodes/data/logical_key_data.g.json
diff --git a/dev/tools/gen_keycodes/data/physical_key_data.json b/dev/tools/gen_keycodes/data/physical_key_data.g.json
similarity index 100%
rename from dev/tools/gen_keycodes/data/physical_key_data.json
rename to dev/tools/gen_keycodes/data/physical_key_data.g.json
diff --git a/dev/tools/gen_keycodes/lib/base_code_gen.dart b/dev/tools/gen_keycodes/lib/base_code_gen.dart
index 9dd0791..a49292b 100644
--- a/dev/tools/gen_keycodes/lib/base_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/base_code_gen.dart
@@ -34,7 +34,7 @@
   Map<String, String> mappings();
 
   /// Substitutes the various platform specific maps into the template file for
-  /// keyboard_maps.dart.
+  /// keyboard_maps.g.dart.
   String generate() {
     final String template = File(templatePath).readAsStringSync();
     return _injectDictionary(template, mappings());
diff --git a/dev/tools/gen_keycodes/lib/gtk_code_gen.dart b/dev/tools/gen_keycodes/lib/gtk_code_gen.dart
index d07668d..983d8f2 100644
--- a/dev/tools/gen_keycodes/lib/gtk_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/gtk_code_gen.dart
@@ -129,7 +129,7 @@
 
   @override
   String outputPath(String platform) => path.join(PlatformCodeGenerator.engineRoot,
-      'shell', 'platform', 'linux', 'key_mapping.cc');
+      'shell', 'platform', 'linux', 'key_mapping.g.cc');
 
   @override
   Map<String, String> mappings() {
diff --git a/dev/tools/gen_keycodes/lib/ios_code_gen.dart b/dev/tools/gen_keycodes/lib/ios_code_gen.dart
index 60f251b..0d9e800 100644
--- a/dev/tools/gen_keycodes/lib/ios_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/ios_code_gen.dart
@@ -122,7 +122,7 @@
 
   @override
   String outputPath(String platform) => path.join(PlatformCodeGenerator.engineRoot,
-      'shell', 'platform', 'darwin', 'ios', 'framework', 'Source', 'KeyCodeMap.mm');
+      'shell', 'platform', 'darwin', 'ios', 'framework', 'Source', 'KeyCodeMap.g.mm');
 
   @override
   Map<String, String> mappings() {
diff --git a/dev/tools/gen_keycodes/lib/keyboard_keys_code_gen.dart b/dev/tools/gen_keycodes/lib/keyboard_keys_code_gen.dart
index 1e35429..2aa39f5 100644
--- a/dev/tools/gen_keycodes/lib/keyboard_keys_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/keyboard_keys_code_gen.dart
@@ -46,7 +46,7 @@
   String get constantName => upperCamelToLowerCamel(name);
 }
 
-/// Generates the keyboard_key.dart based on the information in the key data
+/// Generates the keyboard_key.g.dart based on the information in the key data
 /// structure given to it.
 class KeyboardKeysCodeGenerator extends BaseCodeGenerator {
   KeyboardKeysCodeGenerator(super.keyData, super.logicalData);
diff --git a/dev/tools/gen_keycodes/lib/keyboard_maps_code_gen.dart b/dev/tools/gen_keycodes/lib/keyboard_maps_code_gen.dart
index 28e78b7..cf4e65c 100644
--- a/dev/tools/gen_keycodes/lib/keyboard_maps_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/keyboard_maps_code_gen.dart
@@ -34,7 +34,7 @@
   return charCode >= charDigit0 && charCode <= charDigit9;
 }
 
-/// Generates the keyboard_maps.dart files, based on the information in the key
+/// Generates the keyboard_maps.g.dart files, based on the information in the key
 /// data structure given to it.
 class KeyboardMapsCodeGenerator extends BaseCodeGenerator {
   KeyboardMapsCodeGenerator(super.keyData, super.logicalData);
@@ -176,7 +176,7 @@
   String get _windowsKeyCodeMap {
     final OutputLines<int> lines = OutputLines<int>('Windows key code map');
     for (final LogicalKeyEntry entry in logicalData.entries) {
-      // Letter keys on Windows are not recorded in logical_key_data.json,
+      // Letter keys on Windows are not recorded in logical_key_data.g.json,
       // because they are not used by the embedding. Add them manually.
       final List<int>? keyCodes = entry.windowsValues.isNotEmpty
         ? entry.windowsValues
diff --git a/dev/tools/gen_keycodes/lib/logical_key_data.dart b/dev/tools/gen_keycodes/lib/logical_key_data.dart
index d943192..183ec4e 100644
--- a/dev/tools/gen_keycodes/lib/logical_key_data.dart
+++ b/dev/tools/gen_keycodes/lib/logical_key_data.dart
@@ -569,7 +569,7 @@
 
   /// A string indicating the letter on the keycap of a letter key.
   ///
-  /// This is only used to generate the key label mapping in keyboard_map.dart.
+  /// This is only used to generate the key label mapping in keyboard_maps.g.dart.
   /// [LogicalKeyboardKey.keyLabel] uses a different definition and is generated
   /// differently.
   final String? keyLabel;
@@ -607,7 +607,7 @@
   }
 
   /// Gets the named used for the key constant in the definitions in
-  /// keyboard_key.dart.
+  /// keyboard_key.g.dart.
   ///
   /// If set by the constructor, returns the name set, but otherwise constructs
   /// the name from the various different names available, making sure that the
diff --git a/dev/tools/gen_keycodes/lib/macos_code_gen.dart b/dev/tools/gen_keycodes/lib/macos_code_gen.dart
index 1d49bdf..cbd697e 100644
--- a/dev/tools/gen_keycodes/lib/macos_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/macos_code_gen.dart
@@ -119,7 +119,7 @@
 
   @override
   String outputPath(String platform) => path.join(PlatformCodeGenerator.engineRoot,
-      'shell', 'platform', 'darwin', 'macos', 'framework', 'Source', 'KeyCodeMap.mm');
+      'shell', 'platform', 'darwin', 'macos', 'framework', 'Source', 'KeyCodeMap.g.mm');
 
   @override
   Map<String, String> mappings() {
diff --git a/dev/tools/gen_keycodes/lib/physical_key_data.dart b/dev/tools/gen_keycodes/lib/physical_key_data.dart
index 5bbe5ab..aef81d0 100644
--- a/dev/tools/gen_keycodes/lib/physical_key_data.dart
+++ b/dev/tools/gen_keycodes/lib/physical_key_data.dart
@@ -313,7 +313,7 @@
   String get commentName => getCommentName(constantName);
 
   /// Gets the named used for the key constant in the definitions in
-  /// keyboard_key.dart.
+  /// keyboard_key.g.dart.
   ///
   /// If set by the constructor, returns the name set, but otherwise constructs
   /// the name from the various different names available, making sure that the
diff --git a/dev/tools/gen_keycodes/lib/web_code_gen.dart b/dev/tools/gen_keycodes/lib/web_code_gen.dart
index 3dca72b..37a2898 100644
--- a/dev/tools/gen_keycodes/lib/web_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/web_code_gen.dart
@@ -66,7 +66,7 @@
 
   @override
   String outputPath(String platform) => path.join(PlatformCodeGenerator.engineRoot,
-      'lib', 'web_ui', 'lib', 'src', 'engine', 'key_map.dart');
+      'lib', 'web_ui', 'lib', 'src', 'engine', 'key_map.g.dart');
 
   @override
   Map<String, String> mappings() {
diff --git a/dev/tools/gen_keycodes/lib/windows_code_gen.dart b/dev/tools/gen_keycodes/lib/windows_code_gen.dart
index 7dacaee..4ef32c0 100644
--- a/dev/tools/gen_keycodes/lib/windows_code_gen.dart
+++ b/dev/tools/gen_keycodes/lib/windows_code_gen.dart
@@ -83,7 +83,7 @@
 
   @override
   String outputPath(String platform) => path.join(PlatformCodeGenerator.engineRoot,
-      'shell', 'platform', 'windows', 'flutter_key_map.cc');
+      'shell', 'platform', 'windows', 'flutter_key_map.g.cc');
 
   @override
   Map<String, String> mappings() {
diff --git a/dev/tools/gen_keycodes/test/gen_keycodes_test.dart b/dev/tools/gen_keycodes/test/gen_keycodes_test.dart
index b6e256c..9c53ca7 100644
--- a/dev/tools/gen_keycodes/test/gen_keycodes_test.dart
+++ b/dev/tools/gen_keycodes/test/gen_keycodes_test.dart
@@ -23,9 +23,9 @@
 }
 
 final PhysicalKeyData physicalData = PhysicalKeyData.fromJson(
-    json.decode(readDataFile('physical_key_data.json')) as Map<String, dynamic>);
+    json.decode(readDataFile('physical_key_data.g.json')) as Map<String, dynamic>);
 final LogicalKeyData logicalData = LogicalKeyData.fromJson(
-    json.decode(readDataFile('logical_key_data.json')) as Map<String, dynamic>);
+    json.decode(readDataFile('logical_key_data.g.json')) as Map<String, dynamic>);
 final Map<String, bool> keyGoals = parseMapOfBool(
     readDataFile('layout_goals.json'));
 
@@ -71,7 +71,7 @@
     );
     final String output = codeGenerator.generate();
 
-    expect(codeGenerator.outputPath(platform), endsWith('KeyCodeMap.mm'));
+    expect(codeGenerator.outputPath(platform), endsWith('KeyCodeMap.g.mm'));
     expect(output, contains('kValueMask'));
     expect(output, contains('keyCodeToPhysicalKey'));
     expect(output, contains('keyCodeToLogicalKey'));
@@ -89,7 +89,7 @@
     );
     final String output = codeGenerator.generate();
 
-    expect(codeGenerator.outputPath(platform), endsWith('KeyCodeMap.mm'));
+    expect(codeGenerator.outputPath(platform), endsWith('KeyCodeMap.g.mm'));
     expect(output, contains('kValueMask'));
     expect(output, contains('keyCodeToPhysicalKey'));
     expect(output, contains('keyCodeToLogicalKey'));
@@ -109,7 +109,7 @@
     );
     final String output = codeGenerator.generate();
 
-    expect(codeGenerator.outputPath(platform), endsWith('flutter_key_map.cc'));
+    expect(codeGenerator.outputPath(platform), endsWith('flutter_key_map.g.cc'));
     expect(output, contains('KeyboardKeyEmbedderHandler::windowsToPhysicalMap_'));
     expect(output, contains('KeyboardKeyEmbedderHandler::windowsToLogicalMap_'));
     expect(output, contains('KeyboardKeyEmbedderHandler::scanCodeToLogicalMap_'));
@@ -126,7 +126,7 @@
     );
     final String output = codeGenerator.generate();
 
-    expect(codeGenerator.outputPath(platform), endsWith('key_mapping.cc'));
+    expect(codeGenerator.outputPath(platform), endsWith('key_mapping.g.cc'));
     expect(output, contains('initialize_modifier_bit_to_checked_keys'));
     expect(output, contains('initialize_lock_bit_to_checked_keys'));
     checkCommonOutput(output);
@@ -140,7 +140,7 @@
     );
     final String output = codeGenerator.generate();
 
-    expect(codeGenerator.outputPath(platform), endsWith('key_map.dart'));
+    expect(codeGenerator.outputPath(platform), endsWith('key_map.g.dart'));
     expect(output, contains('kWebToLogicalKey'));
     expect(output, contains('kWebToPhysicalKey'));
     expect(output, contains('kWebLogicalLocationMap'));
diff --git a/packages/flutter/lib/services.dart b/packages/flutter/lib/services.dart
index bcf7988..370df35 100644
--- a/packages/flutter/lib/services.dart
+++ b/packages/flutter/lib/services.dart
@@ -20,8 +20,8 @@
 export 'src/services/font_loader.dart';
 export 'src/services/haptic_feedback.dart';
 export 'src/services/hardware_keyboard.dart';
-export 'src/services/keyboard_key.dart';
-export 'src/services/keyboard_maps.dart';
+export 'src/services/keyboard_key.g.dart';
+export 'src/services/keyboard_maps.g.dart';
 export 'src/services/message_codec.dart';
 export 'src/services/message_codecs.dart';
 export 'src/services/mouse_cursor.dart';
diff --git a/packages/flutter/lib/src/services/hardware_keyboard.dart b/packages/flutter/lib/src/services/hardware_keyboard.dart
index 8ab8002..493b4ed 100644
--- a/packages/flutter/lib/src/services/hardware_keyboard.dart
+++ b/packages/flutter/lib/src/services/hardware_keyboard.dart
@@ -13,7 +13,7 @@
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show RawKeyboard, RawKeyEvent;
 
 /// Represents a lock mode of a keyboard, such as [KeyboardLockMode.capsLock].
diff --git a/packages/flutter/lib/src/services/keyboard_key.dart b/packages/flutter/lib/src/services/keyboard_key.g.dart
similarity index 100%
rename from packages/flutter/lib/src/services/keyboard_key.dart
rename to packages/flutter/lib/src/services/keyboard_key.g.dart
diff --git a/packages/flutter/lib/src/services/keyboard_maps.dart b/packages/flutter/lib/src/services/keyboard_maps.g.dart
similarity index 99%
rename from packages/flutter/lib/src/services/keyboard_maps.dart
rename to packages/flutter/lib/src/services/keyboard_maps.g.dart
index 18aeb35..66abf82 100644
--- a/packages/flutter/lib/src/services/keyboard_maps.dart
+++ b/packages/flutter/lib/src/services/keyboard_maps.g.dart
@@ -9,9 +9,9 @@
 // Edit the template dev/tools/gen_keycodes/data/keyboard_maps.tmpl instead.
 // See dev/tools/gen_keycodes/README.md for more information.
 
-import 'keyboard_key.dart';
+import 'keyboard_key.g.dart';
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 
 /// Maps Android-specific key codes to the matching [LogicalKeyboardKey].
 const Map<int, LogicalKeyboardKey> kAndroidToLogicalKey = <int, LogicalKeyboardKey>{
diff --git a/packages/flutter/lib/src/services/raw_keyboard.dart b/packages/flutter/lib/src/services/raw_keyboard.dart
index 1520a6c..937081e 100644
--- a/packages/flutter/lib/src/services/raw_keyboard.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard.dart
@@ -7,7 +7,7 @@
 
 import 'binding.dart';
 import 'hardware_keyboard.dart';
-import 'keyboard_key.dart';
+import 'keyboard_key.g.dart';
 import 'raw_keyboard_android.dart';
 import 'raw_keyboard_fuchsia.dart';
 import 'raw_keyboard_ios.dart';
@@ -19,7 +19,7 @@
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder, ValueChanged;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 
 /// An enum describing the side of the keyboard that a key is on, to allow
 /// discrimination between which key is pressed (e.g. the left or right SHIFT
diff --git a/packages/flutter/lib/src/services/raw_keyboard_android.dart b/packages/flutter/lib/src/services/raw_keyboard_android.dart
index e7d1764..c74ea76 100644
--- a/packages/flutter/lib/src/services/raw_keyboard_android.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard_android.dart
@@ -4,12 +4,12 @@
 
 import 'package:flutter/foundation.dart';
 
-import 'keyboard_maps.dart';
+import 'keyboard_maps.g.dart';
 import 'raw_keyboard.dart';
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show KeyboardSide, ModifierKey;
 
 // Android sets the 0x80000000 bit on a character to indicate that it is a
diff --git a/packages/flutter/lib/src/services/raw_keyboard_fuchsia.dart b/packages/flutter/lib/src/services/raw_keyboard_fuchsia.dart
index da047bb..5158117 100644
--- a/packages/flutter/lib/src/services/raw_keyboard_fuchsia.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard_fuchsia.dart
@@ -4,12 +4,12 @@
 
 import 'package:flutter/foundation.dart';
 
-import 'keyboard_maps.dart';
+import 'keyboard_maps.g.dart';
 import 'raw_keyboard.dart';
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show KeyboardSide, ModifierKey;
 
 /// Platform-specific key event data for Fuchsia.
diff --git a/packages/flutter/lib/src/services/raw_keyboard_ios.dart b/packages/flutter/lib/src/services/raw_keyboard_ios.dart
index df86f35..f5f952c 100644
--- a/packages/flutter/lib/src/services/raw_keyboard_ios.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard_ios.dart
@@ -4,12 +4,12 @@
 
 import 'package:flutter/foundation.dart';
 
-import 'keyboard_maps.dart';
+import 'keyboard_maps.g.dart';
 import 'raw_keyboard.dart';
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show KeyboardSide, ModifierKey;
 
 /// Maps iOS specific string values of nonvisible keys to logical keys
diff --git a/packages/flutter/lib/src/services/raw_keyboard_linux.dart b/packages/flutter/lib/src/services/raw_keyboard_linux.dart
index 8f58243..c7e0d21 100644
--- a/packages/flutter/lib/src/services/raw_keyboard_linux.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard_linux.dart
@@ -4,12 +4,12 @@
 
 import 'package:flutter/foundation.dart';
 
-import 'keyboard_maps.dart';
+import 'keyboard_maps.g.dart';
 import 'raw_keyboard.dart';
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show KeyboardSide, ModifierKey;
 
 /// Platform-specific key event data for Linux.
diff --git a/packages/flutter/lib/src/services/raw_keyboard_macos.dart b/packages/flutter/lib/src/services/raw_keyboard_macos.dart
index bbc82e8..952ec0c 100644
--- a/packages/flutter/lib/src/services/raw_keyboard_macos.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard_macos.dart
@@ -4,12 +4,12 @@
 
 import 'package:flutter/foundation.dart';
 
-import 'keyboard_maps.dart';
+import 'keyboard_maps.g.dart';
 import 'raw_keyboard.dart';
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show KeyboardSide, ModifierKey;
 
 /// Convert a UTF32 rune to its lower case.
diff --git a/packages/flutter/lib/src/services/raw_keyboard_web.dart b/packages/flutter/lib/src/services/raw_keyboard_web.dart
index 8d6fcad..aad8913 100644
--- a/packages/flutter/lib/src/services/raw_keyboard_web.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard_web.dart
@@ -4,12 +4,12 @@
 
 import 'package:flutter/foundation.dart';
 
-import 'keyboard_maps.dart';
+import 'keyboard_maps.g.dart';
 import 'raw_keyboard.dart';
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show KeyboardSide, ModifierKey;
 
 String? _unicodeChar(String key) {
diff --git a/packages/flutter/lib/src/services/raw_keyboard_windows.dart b/packages/flutter/lib/src/services/raw_keyboard_windows.dart
index 1e393cb..d9f9797 100644
--- a/packages/flutter/lib/src/services/raw_keyboard_windows.dart
+++ b/packages/flutter/lib/src/services/raw_keyboard_windows.dart
@@ -4,12 +4,12 @@
 
 import 'package:flutter/foundation.dart';
 
-import 'keyboard_maps.dart';
+import 'keyboard_maps.g.dart';
 import 'raw_keyboard.dart';
 
 export 'package:flutter/foundation.dart' show DiagnosticPropertiesBuilder;
 
-export 'keyboard_key.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
+export 'keyboard_key.g.dart' show LogicalKeyboardKey, PhysicalKeyboardKey;
 export 'raw_keyboard.dart' show KeyboardSide, ModifierKey;
 
 // Virtual key VK_PROCESSKEY in Win32 API.
diff --git a/packages/flutter/test/material/ink_well_test.dart b/packages/flutter/test/material/ink_well_test.dart
index a9db62f..113d72e 100644
--- a/packages/flutter/test/material/ink_well_test.dart
+++ b/packages/flutter/test/material/ink_well_test.dart
@@ -5,7 +5,7 @@
 import 'package:flutter/gestures.dart';
 import 'package:flutter/material.dart';
 import 'package:flutter/rendering.dart';
-import 'package:flutter/src/services/keyboard_key.dart';
+import 'package:flutter/src/services/keyboard_key.g.dart';
 import 'package:flutter_test/flutter_test.dart';
 
 import '../rendering/mock_canvas.dart';
diff --git a/packages/flutter/test/material/raw_material_button_test.dart b/packages/flutter/test/material/raw_material_button_test.dart
index 815e03a..9bacdd2 100644
--- a/packages/flutter/test/material/raw_material_button_test.dart
+++ b/packages/flutter/test/material/raw_material_button_test.dart
@@ -6,7 +6,7 @@
 import 'package:flutter/gestures.dart';
 import 'package:flutter/material.dart';
 import 'package:flutter/rendering.dart';
-import 'package:flutter/src/services/keyboard_key.dart';
+import 'package:flutter/src/services/keyboard_key.g.dart';
 import 'package:flutter_test/flutter_test.dart';
 
 import '../rendering/mock_canvas.dart';