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

Side by Side Diff: sky/sdk/home.dart

Issue 1218153005: Refactoring to support dark theme better (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: fix import issues 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
« no previous file with comments | « sky/sdk/example/widgets/tabs.dart ('k') | sky/sdk/lib/editing/input.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 'dart:sky'; 5 import 'dart:sky';
6 6
7 import 'package:mojom/intents/intents.mojom.dart'; 7 import 'package:mojom/intents/intents.mojom.dart';
8 import 'package:sky/mojo/shell.dart' as shell; 8 import 'package:sky/mojo/shell.dart' as shell;
9 import 'package:sky/painting/box_painter.dart'; 9 import 'package:sky/painting/box_painter.dart';
10 import 'package:sky/theme/colors.dart' as colors; 10 import 'package:sky/theme/colors.dart' as colors;
11 import 'package:sky/theme/edges.dart';
12 import 'package:sky/theme/typography.dart' as typography; 11 import 'package:sky/theme/typography.dart' as typography;
13 import 'package:sky/widgets/basic.dart'; 12 import 'package:sky/widgets/basic.dart';
14 import 'package:sky/widgets/card.dart'; 13 import 'package:sky/widgets/card.dart';
15 import 'package:sky/widgets/fixed_height_scrollable.dart'; 14 import 'package:sky/widgets/fixed_height_scrollable.dart';
16 import 'package:sky/widgets/flat_button.dart'; 15 import 'package:sky/widgets/flat_button.dart';
17 import 'package:sky/widgets/material.dart'; 16 import 'package:sky/widgets/material.dart';
18 import 'package:sky/widgets/scaffold.dart'; 17 import 'package:sky/widgets/scaffold.dart';
19 import 'package:sky/widgets/theme.dart'; 18 import 'package:sky/widgets/theme.dart';
20 import 'package:sky/widgets/tool_bar.dart'; 19 import 'package:sky/widgets/tool_bar.dart';
21 20
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
163 .skip(start) 162 .skip(start)
164 .take(count) 163 .take(count)
165 .map(buildDemo) 164 .map(buildDemo)
166 .toList(growable: false); 165 .toList(growable: false);
167 } 166 }
168 } 167 }
169 168
170 class SkyHome extends App { 169 class SkyHome extends App {
171 Widget build() { 170 Widget build() {
172 return new Theme( 171 return new Theme(
173 data: new ThemeData.dark( 172 data: new ThemeData(
174 primary: colors.Teal, 173 brightness: ThemeBrightness.dark,
175 accent: colors.Orange 174 primarySwatch: colors.Teal
176 ), 175 ),
177 child: new Scaffold( 176 child: new Scaffold(
178 toolbar: new ToolBar(center: new Text('Sky Demos')), 177 toolbar: new ToolBar(center: new Text('Sky Demos')),
179 body: new Material( 178 body: new Material(
180 edge: MaterialEdge.canvas, 179 type: MaterialType.canvas,
181 child: new DemoList() 180 child: new DemoList()
182 ) 181 )
183 ) 182 )
184 ); 183 );
185 } 184 }
186 } 185 }
187 186
188 void main() { 187 void main() {
189 runApp(new SkyHome()); 188 runApp(new SkyHome());
190 } 189 }
OLDNEW
« no previous file with comments | « sky/sdk/example/widgets/tabs.dart ('k') | sky/sdk/lib/editing/input.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698