From bb683e03f6ebae02f89d22e2144f3378e778db84 Mon Sep 17 00:00:00 2001 From: Hixie Date: Mon, 15 Jun 2015 17:32:13 -0700 Subject: [PATCH] Make RaisedButton support being disabled. R=jackson@google.com Review URL: https://codereview.chromium.org/1179943005. --- examples/widgets/container.dart | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/examples/widgets/container.dart b/examples/widgets/container.dart index 14ba1de13d4..7255ac4aeb9 100644 --- a/examples/widgets/container.dart +++ b/examples/widgets/container.dart @@ -24,10 +24,19 @@ class ContainerApp extends App { key: 'b', decoration: new BoxDecoration(backgroundColor: const Color(0xFFFFFF00)), padding: new EdgeDims.symmetric(horizontal: 50.0, vertical: 75.0), - child: new RaisedButton( - child: new Text('PRESS ME'), - onPressed: () => print("Hello World") - ) + child: new Flex([ + new RaisedButton( + key: 'b1', + child: new Text('PRESS ME'), + onPressed: () => print("Hello World") + ), + new RaisedButton( + key: 'b2', + child: new Text('DISABLED'), + onPressed: () => print("Hello World"), + enabled: false + ) + ]) ), new FlexExpandingChild( new Container(