Improve hitTestSelf and hitTestChildren docs (#4484)

Fixes #4427
This commit is contained in:
Adam Barth 2016-06-09 10:10:13 -07:00
parent 2be1eb480f
commit 696f4710f1

View File

@ -1177,6 +1177,9 @@ abstract class RenderBox extends RenderObject {
/// Override this function if this render object can be hit even if its
/// children were not hit.
///
/// Used by [hitTest]. If you override [hitTest] and do not call this
/// function, then you don't need to implement this function.
@protected
bool hitTestSelf(Point position) => false;
@ -1186,6 +1189,9 @@ abstract class RenderBox extends RenderObject {
/// Typically children should be hit tested in reverse paint order so that
/// hit tests at locations where children overlap hit the child that is
/// visually "on top" (i.e., paints later).
///
/// Used by [hitTest]. If you override [hitTest] and do not call this
/// function, then you don't need to implement this function.
@protected
bool hitTestChildren(HitTestResult result, { Point position }) => false;