Makes it easier to hit IconButton

The right fix here is to use a radial reaction, but for now we can just make
the gesture detector including the padding acround the icon in its hit test
region.

Fixes #575
This commit is contained in:
Adam Barth
2015-11-30 17:38:26 -08:00
parent 08dbc7d6fb
commit 4e6b5267d3

View File

@@ -26,6 +26,7 @@ class IconButton extends StatelessComponent {
// 8.0 pixel padding as well as the icon.
return new GestureDetector(
onTap: onPressed,
behavior: HitTestBehavior.opaque,
child: new Padding(
padding: const EdgeDims.all(8.0),
child: new Icon(