Skip to content

Make BoxDecoration replaceable. - #781

Merged
Hixie merged 1 commit into
flutter:masterfrom
Hixie:box_decoration
Dec 8, 2015
Merged

Hixie merged 1 commit into
flutter:masterfrom
Hixie:box_decoration

Conversation

@Hixie

@Hixie Hixie commented Dec 7, 2015

Copy link
Copy Markdown
Contributor

Factor out a reusable interface called Decoration from BoxDecoration.

Make all the consumers of BoxDecoration and the erstwhile BoxPainter
into consumers of Decoration.

Make a BoxPainter be something you get from a Decoration, rather than
something to which you pass a BoxDecoration.

Rename Shape to BoxShape now that it's documented specifically as
applying to boxes.

Move EdgeDims to its own file.

Move FractionalOffset up so that it's with the other helper classes in
its file rather than alone at the end.

Minor change to RenderClipOval's hit testing to avoid taking an
unnecessary square root.

Rename BoxDecorationPosition to DecorationPosition since
RenderDecoratedBox now takes any Decoration.

Implement hit testing for rounded rects.

Rename AnimatedBoxDecorationValue to AnimatedDecorationValue, and make
it support lerping across any Decoration (by deferring to the objects
involved).

@Hixie

Hixie commented Dec 7, 2015

Copy link
Copy Markdown
Contributor Author

(This depends on the RRect changes to the engine that haven't been released yet.)

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.

I don't think we should use this mechanism in this example.

@abarth

abarth commented Dec 7, 2015

Copy link
Copy Markdown
Contributor

LGTM

Factor out a reusable interface called Decoration from BoxDecoration.

Make all the consumers of BoxDecoration and the erstwhile BoxPainter
into consumers of Decoration.

Make a BoxPainter be something you get from a Decoration, rather than
something to which you pass a BoxDecoration.

Rename Shape to BoxShape now that it's documented specifically as
applying to boxes.

Move EdgeDims to its own file.

Move FractionalOffset up so that it's with the other helper classes in
its file rather than alone at the end.

Minor change to RenderClipOval's hit testing to avoid taking an
unnecessary square root.

Rename BoxDecorationPosition to DecorationPosition since
RenderDecoratedBox now takes any Decoration.

Implement hit testing for rounded rects.

Rename AnimatedBoxDecorationValue to AnimatedDecorationValue, and make
it support lerping across any Decoration (by deferring to the objects
involved).
Hixie added a commit that referenced this pull request Dec 8, 2015
Make BoxDecoration replaceable.
@Hixie
Hixie merged commit 2a69a98 into flutter:master Dec 8, 2015
@Hixie
Hixie deleted the box_decoration branch December 8, 2015 05:38
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Aug 17, 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.

2 participants