Skip to content

Conversation

xster
Copy link
Member

@xster xster commented Oct 17, 2018

@@ -1528,7 +1532,8 @@ class _NavigationBarComponentsTransition {
topLargeExpanded = topNavBar.largeExpanded,
transitionBox =
// paintBounds are based on offset zero so it's ok to expand the Rects.
bottomNavBar.renderBox.paintBounds.expandToInclude(topNavBar.renderBox.paintBounds);
bottomNavBar.renderBox.paintBounds.expandToInclude(topNavBar.renderBox.paintBounds),
forwardDirection = directionality == TextDirection.ltr ? 1.0 : -1.0;
Copy link
Contributor

Choose a reason for hiding this comment

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

test for rtl rather than ltr, that way in the unlikely event that we add a value to TextDirection, this will fail more obviously for us people who use LTR.

Copy link
Member Author

Choose a reason for hiding this comment

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

my math is likely failing me but I don't think there's a concise way of arranging this such that on a new enum value, the ltr outcome ends up with a wrong / non-1.0 value is there?

await tester.pump(const Duration(milliseconds: 150));

checkOpacity(
tester, flying(tester, find.text('Page 2')), 0.6753286570310593);
Copy link
Contributor

Choose a reason for hiding this comment

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

there's no need to wrap here, but if you do, use flutter style wrapping so it's easier to see where the expression ends.

Copy link
Member Author

Choose a reason for hiding this comment

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

cleaned up here and above

@Hixie
Copy link
Contributor

Hixie commented Oct 18, 2018

LGTM modulo comments

@xster xster merged commit d00a549 into flutter:master Oct 24, 2018
@xster xster deleted the transition-rtl branch October 24, 2018 21:37
Xavjer pushed a commit to Xavjer/flutter that referenced this pull request Nov 1, 2018
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 9, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants