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

Unified Diff: sky/framework/components/scaffold.dart

Issue 1132063007: Rationalize Dart mojo and sky package structure (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « sky/framework/components/radio.dart ('k') | sky/framework/components/scrollable.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/framework/components/scaffold.dart
diff --git a/sky/framework/components/scaffold.dart b/sky/framework/components/scaffold.dart
deleted file mode 100644
index d66e5e00b060881941e40f2ed18396e11cdd3ea4..0000000000000000000000000000000000000000
--- a/sky/framework/components/scaffold.dart
+++ /dev/null
@@ -1,68 +0,0 @@
-// Copyright 2015 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-import '../fn.dart';
-import '../layout.dart';
-import 'drawer.dart';
-import 'floating_action_button.dart';
-import 'package:sky/framework/theme/typography.dart' as typography;
-
-class Scaffold extends Component {
- static final Style _style = new Style('''
- ${typography.typeface};
- ${typography.black.body1};''');
-
- static final Style _mainStyle = new Style('''
- height: -webkit-fill-available;''');
-
- static final FlexBoxParentData _contentParentData = new FlexBoxParentData()..flex = 1;
-
- static final Style _fabStyle = new Style('''
- position: absolute;
- bottom: 16px;
- right: 16px;''');
-
- static final Style _drawerStyle = new Style('''
- position: absolute;
- top: 0;
- left: 0;
- bottom: 0;
- right: 0;''');
-
- UINode header;
- UINode content;
- FloatingActionButton fab;
- Drawer drawer;
- List<UINode> overlays;
-
- Scaffold({
- Object key,
- this.header,
- this.content,
- this.fab,
- this.drawer,
- this.overlays
- }) : super(key: key);
-
- UINode build() {
- List<UINode> children = [
- new FlexContainer(
- key: 'Main',
- direction: FlexDirection.Column,
- style: _mainStyle,
- children: [header, new ParentDataNode(content, _contentParentData)])
- ];
-
- if (fab != null)
- children.add(new StyleNode(fab, _fabStyle));
-
- if (drawer != null)
- children.add(new StyleNode(drawer, _drawerStyle));
-
- if (overlays != null)
- children.addAll(overlays);
-
- return new Container(style: _style, children: children);
- }
-}
« no previous file with comments | « sky/framework/components/radio.dart ('k') | sky/framework/components/scrollable.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698