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

Side by Side Diff: sky/sdk/lib/widgets/dialog.dart

Issue 1241483002: Improve drawer menu items (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 5 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
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/theme/colors.dart' as colors; 5 import 'package:sky/theme/colors.dart' as colors;
6 import 'package:sky/widgets/basic.dart'; 6 import 'package:sky/widgets/basic.dart';
7 import 'package:sky/widgets/default_text_style.dart'; 7 import 'package:sky/widgets/default_text_style.dart';
8 import 'package:sky/widgets/material.dart'; 8 import 'package:sky/widgets/material.dart';
9 import 'package:sky/widgets/scrollable_viewport.dart'; 9 import 'package:sky/widgets/scrollable_viewport.dart';
10 import 'package:sky/widgets/theme.dart'; 10 import 'package:sky/widgets/theme.dart';
(...skipping 21 matching lines...) Expand all
32 /// The (optional) set of actions that are displayed at the bottom of the 32 /// The (optional) set of actions that are displayed at the bottom of the
33 /// dialog. 33 /// dialog.
34 final List<Widget> actions; 34 final List<Widget> actions;
35 35
36 /// An (optional) callback that is called when the dialog is dismissed. 36 /// An (optional) callback that is called when the dialog is dismissed.
37 final Function onDismiss; 37 final Function onDismiss;
38 38
39 Color get _color { 39 Color get _color {
40 switch (Theme.of(this).brightness) { 40 switch (Theme.of(this).brightness) {
41 case ThemeBrightness.light: 41 case ThemeBrightness.light:
42 return colors.White; 42 return colors.white;
43 case ThemeBrightness.dark: 43 case ThemeBrightness.dark:
44 return colors.Grey[800]; 44 return colors.Grey[800];
45 } 45 }
46 } 46 }
47 47
48 Widget build() { 48 Widget build() {
49 Container mask = new Container( 49 Container mask = new Container(
50 decoration: const BoxDecoration( 50 decoration: const BoxDecoration(
51 backgroundColor: const Color(0x7F000000))); 51 backgroundColor: const Color(0x7F000000)));
52 52
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 child: new ShrinkWrapWidth( 91 child: new ShrinkWrapWidth(
92 child: new ScrollableBlock(children) 92 child: new ScrollableBlock(children)
93 ) 93 )
94 ) 94 )
95 ) 95 )
96 ) 96 )
97 ) 97 )
98 ]); 98 ]);
99 } 99 }
100 } 100 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698