Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(689)

Side by Side Diff: sky/examples/stocks2/lib/stock_settings.dart

Issue 1178723010: Make the popup menu work again. (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « sky/examples/stocks2/lib/stock_row.dart ('k') | sky/sdk/lib/widgets/basic.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 import 'package:sky/theme2/colors.dart' as colors; 5 import 'package:sky/theme2/colors.dart' as colors;
6 import 'package:sky/theme2/typography.dart' as typography; 6 import 'package:sky/theme2/typography.dart' as typography;
7 import 'package:sky/widgets/basic.dart'; 7 import 'package:sky/widgets/basic.dart';
8 import 'package:sky/widgets/checkbox.dart'; 8 import 'package:sky/widgets/checkbox.dart';
9 import 'package:sky/widgets/icon_button.dart'; 9 import 'package:sky/widgets/icon_button.dart';
10 import 'package:sky/widgets/menu_item.dart'; 10 import 'package:sky/widgets/menu_item.dart';
(...skipping 23 matching lines...) Expand all
34 backgroundColor: colors.Purple[500] 34 backgroundColor: colors.Purple[500]
35 ); 35 );
36 } 36 }
37 37
38 Widget buildSettingsPane() { 38 Widget buildSettingsPane() {
39 return new Container( 39 return new Container(
40 padding: const EdgeDims.symmetric(vertical: 20.0), 40 padding: const EdgeDims.symmetric(vertical: 20.0),
41 decoration: new BoxDecoration(backgroundColor: colors.Grey[50]), 41 decoration: new BoxDecoration(backgroundColor: colors.Grey[50]),
42 child: new Block([ 42 child: new Block([
43 new MenuItem( 43 new MenuItem(
44 key: 'Optimistic Setting',
45 icon: 'action/thumb_up', 44 icon: 'action/thumb_up',
46 onGestureTap: (event) => _handleAwesomeChanged(!_awesome), 45 onGestureTap: (event) => _handleAwesomeChanged(!_awesome),
47 children: [ 46 children: [
48 new Flexible(child: new Text('Everything is awesome')), 47 new Flexible(child: new Text('Everything is awesome')),
49 new Checkbox(key: 'awesome', value: _awesome, onChanged: _handleAwes omeChanged) 48 new Checkbox(value: _awesome, onChanged: _handleAwesomeChanged)
50 ] 49 ]
51 ), 50 ),
52 ]) 51 ])
53 ); 52 );
54 } 53 }
55 54
56 Widget build() { 55 Widget build() {
57 return new Scaffold( 56 return new Scaffold(
58 toolbar: buildToolBar(), 57 toolbar: buildToolBar(),
59 body: buildSettingsPane() 58 body: buildSettingsPane()
60 ); 59 );
61 } 60 }
62 } 61 }
OLDNEW
« no previous file with comments | « sky/examples/stocks2/lib/stock_row.dart ('k') | sky/sdk/lib/widgets/basic.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698