Make Demos in flutter_gallery more accessible (#10832)

Remaining known issues are #10831 and #10830.
This commit is contained in:
Michael Goderbauer 2017-06-20 11:09:57 -07:00 committed by GitHub
parent 7d16a96500
commit 0e1b652d53
3 changed files with 109 additions and 101 deletions

View File

@ -70,12 +70,14 @@ class _ContactItem extends StatelessWidget {
) )
)); ));
} }
return new Padding( return new MergeSemantics(
child: new Padding(
padding: const EdgeInsets.symmetric(vertical: 16.0), padding: const EdgeInsets.symmetric(vertical: 16.0),
child: new Row( child: new Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween, mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: rowChildren children: rowChildren
) )
),
); );
} }
} }

View File

@ -246,7 +246,8 @@ class RecipeCard extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return new GestureDetector( return new MergeSemantics(
child: new GestureDetector(
onTap: onTap, onTap: onTap,
child: new Card( child: new Card(
child: new Column( child: new Column(
@ -283,6 +284,7 @@ class RecipeCard extends StatelessWidget {
], ],
), ),
), ),
),
); );
} }
} }

View File

@ -252,7 +252,8 @@ class _Heading extends StatelessWidget {
Widget build(BuildContext context) { Widget build(BuildContext context) {
final Size screenSize = MediaQuery.of(context).size; final Size screenSize = MediaQuery.of(context).size;
final ShrineTheme theme = ShrineTheme.of(context); final ShrineTheme theme = ShrineTheme.of(context);
return new SizedBox( return new MergeSemantics(
child: new SizedBox(
height: screenSize.width > screenSize.height height: screenSize.width > screenSize.height
? (screenSize.height - kToolbarHeight) * 0.85 ? (screenSize.height - kToolbarHeight) * 0.85
: (screenSize.height - kToolbarHeight) * 0.70, : (screenSize.height - kToolbarHeight) * 0.70,
@ -287,6 +288,7 @@ class _Heading extends StatelessWidget {
], ],
), ),
), ),
),
); );
} }
} }
@ -303,7 +305,8 @@ class _ProductItem extends StatelessWidget {
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return new Card( return new MergeSemantics(
child: new Card(
child: new Stack( child: new Stack(
children: <Widget>[ children: <Widget>[
new Column( new Column(
@ -333,6 +336,7 @@ class _ProductItem extends StatelessWidget {
), ),
], ],
), ),
),
); );
} }
} }