-
Notifications
You must be signed in to change notification settings - Fork 29.8k
[framework] avoid compositing with visibility #111844
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
[framework] avoid compositing with visibility #111844
Conversation
goderbauer
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
| // found in the LICENSE file. | ||
|
|
||
| import 'package:flutter/foundation.dart'; | ||
| import 'package:flutter/rendering.dart'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The overall class comment below still mentions that this may use the Opacity widget behind the scenes. Maybe update that? We should probably still link to the Opacity widget in the see also section, though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same fro the class comment on SliverVisibility
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I do see links to the Opacity/SliverOpacity widgets, but I can't see any comments that directly state that this uses opacity
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I interpreted "These widgets provide some of the facets of this one:" as such. But I don't feel strongly about this comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I still want to link to those widgets, I don't see that as necessarily claiming the implementation uses Opacity but providing a hint on a similar way to achieve the same effect.
When maintaining state with the
Visibility/SliverVisibilitywidgets, the framework uses anOpacity/SliverOpacitywidget. Unfortunately since we've started preserving the opacity layer at fully opaque, this is no longer free and forces additional compositing.Add new special purpose visibility widgets that do not force compositing