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

Make SemanticsNode.isMergedIntoParent Readonly #6617

Merged
merged 4 commits into from
Oct 31, 2023
Merged

Conversation

CaseyHillers
Copy link
Contributor

Follow up from flutter/flutter#137304

Breaks Google testing (b/308325747)

Pre-launch Checklist

  • I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
  • I read the [Tree Hygiene] wiki page, which explains my responsibilities.
  • I read the [Flutter Style Guide] recently, and have followed its advice.
  • I signed the [CLA].
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or there is a reason for not adding tests.

@CaseyHillers CaseyHillers requested a review from a team as a code owner October 29, 2023 17:04
@CaseyHillers CaseyHillers requested review from kenzieschmoll and removed request for a team October 29, 2023 17:04
Copy link

@LongCatIsLooong LongCatIsLooong left a comment

Choose a reason for hiding this comment

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

Sorry for the breakage and thank you for the fix!

The upstream flutter/flutter change removed the isMergedIntoParent setter because it's no longer needed. The framework now manages that flag for you.

@Jasguerrero
Copy link

Is this the correct fix @LongCatIsLooong ? Although not blocking roll since a fix for b/308325747 was already applied we still want this right?

@LongCatIsLooong
Copy link

Yeah the fix LGTM.

@CaseyHillers
Copy link
Contributor Author

@kenzieschmoll can you take a look? This is going to block the Dart SDK roll into Google.

Let me know if we need release notes for this change. For now, I'm going to mark it as exempt.

Comment on lines 814 to 815
_innerNode ??= SemanticsNode(showOnScreen: showOnScreen);
_innerNode!
..isMergedIntoParent = node.isPartOfNodeMerging
..rect = Offset.zero & node.rect.size;
_innerNode!.rect = Offset.zero & node.rect.size;
Copy link
Member

Choose a reason for hiding this comment

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

can we do instead what is done on flutter master?
(_innerNode ??= SemanticsNode(showOnScreen: showOnScreen)).rect = node.rect;

(Most of the code in this file is copied from scrollable.dart from the Flutter framework)

@kenzieschmoll kenzieschmoll merged commit 7fa6761 into master Oct 31, 2023
21 checks passed
@kenzieschmoll kenzieschmoll deleted the b308325747 branch October 31, 2023 19:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants