Skip to content

Remove setup_hooks.dart and move _setupHooks back into natives.dart#181008

Merged
auto-submit[bot] merged 2 commits into
flutter:masterfrom
jason-simmons:remove_setup_hooks_dart
Jan 15, 2026
Merged

Remove setup_hooks.dart and move _setupHooks back into natives.dart#181008
auto-submit[bot] merged 2 commits into
flutter:masterfrom
jason-simmons:remove_setup_hooks_dart

Conversation

@jason-simmons

Copy link
Copy Markdown
Member

_setupHooks had been extracted into a separate file as part of Impeller Scene, which was later removed from the engine.

setup_hooks.dart was not distributed with Flutter releases, and the reference to a nonexistent file in the dart:ui library caused issues for tools like source_gen

_setupHooks had been extracted into a separate file as part of Impeller Scene, which was later removed from the engine.

setup_hooks.dart was not distributed with Flutter releases, and the reference to a nonexistent file in the dart:ui library caused issues for tools like source_gen
@flutter-dashboard

Copy link
Copy Markdown

It looks like this pull request may not have tests. Please make sure to add tests or get an explicit test exemption before merging.

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing. If you believe this PR qualifies for a test exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!). The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group.

@github-actions github-actions Bot added the engine flutter/engine related. See also e: labels. label Jan 14, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request refactors the _setupHooks function by moving it from its own file, setup_hooks.dart, back into natives.dart. This cleanup is being done because setup_hooks.dart was part of a feature that has since been removed, and its presence as a non-distributed file was causing issues for some development tools. The change also includes removing the corresponding part directive from ui.dart. The changes are correct and improve the codebase organization. I have one suggestion to improve readability by reordering a constant definition.

Comment thread engine/src/flutter/lib/ui/natives.dart Outdated
@jason-simmons jason-simmons added the autosubmit Merge PR when tree becomes green via auto submit App label Jan 14, 2026
@auto-submit auto-submit Bot added this pull request to the merge queue Jan 15, 2026
Merged via the queue into flutter:master with commit 7d755d1 Jan 15, 2026
179 checks passed
@flutter-dashboard flutter-dashboard Bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Jan 15, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 15, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 15, 2026
ikramhasan pushed a commit to ikramhasan/flutter that referenced this pull request Jan 15, 2026
…lutter#181008)

_setupHooks had been extracted into a separate file as part of Impeller
Scene, which was later removed from the engine.

setup_hooks.dart was not distributed with Flutter releases, and the
reference to a nonexistent file in the dart:ui library caused issues for
tools like source_gen
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 16, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 16, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 16, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 16, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 16, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 16, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 17, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 17, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 17, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 18, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 18, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 19, 2026
calltekk pushed a commit to calltekk/flutter that referenced this pull request Jan 19, 2026
…lutter#181008)

_setupHooks had been extracted into a separate file as part of Impeller
Scene, which was later removed from the engine.

setup_hooks.dart was not distributed with Flutter releases, and the
reference to a nonexistent file in the dart:ui library caused issues for
tools like source_gen
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 19, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 19, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 20, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 20, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 20, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 20, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 20, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 21, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 21, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 21, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 22, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 22, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 22, 2026
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Jan 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

engine flutter/engine related. See also e: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants