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

Unified Diff: sky/sdk/lib/framework/components2/tool_bar.dart

Issue 1171173003: Right-size the toolbar (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Toolbar contents bottom-justfied, stretch past notification area 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 side-by-side diff with in-line comments
Download patch
Index: sky/sdk/lib/framework/components2/tool_bar.dart
diff --git a/sky/sdk/lib/framework/components2/tool_bar.dart b/sky/sdk/lib/framework/components2/tool_bar.dart
index a90afed8080df4842319d736c86d6ea9ecaaea70..a8e05e1f6a518f9979a8b2de18d71beaddd05164 100644
--- a/sky/sdk/lib/framework/components2/tool_bar.dart
+++ b/sky/sdk/lib/framework/components2/tool_bar.dart
@@ -3,7 +3,8 @@
// found in the LICENSE file.
import '../fn2.dart';
-import '../theme/view_configuration.dart';
+import '../rendering/flex.dart';
+import '../theme2/view_configuration.dart';
import '../theme2/shadows.dart';
class ToolBar extends Component {
@@ -34,13 +35,16 @@ class ToolBar extends Component {
if (right != null)
children.addAll(right);
+ var bottomJustifiedChild = new FlexContainer(
abarth-chromium 2015/06/10 17:50:40 Can you add a TODO comment about this being a work
hansmuller 2015/06/10 17:56:10 Done.
Hixie 2015/06/10 17:57:13 UINode, not var.
+ direction: FlexDirection.vertical,
+ justifyContent: FlexJustifyContent.flexEnd,
+ children: [new Container(
+ child: new FlexContainer(children: children),
+ height: kToolBarHeight)]);
+
return new Container(
- child: new FlexContainer(
- children: children,
- direction: FlexDirection.horizontal
- ),
- height: 56.0,
- padding: new EdgeDims(kStatusBarHeight.toDouble(), 8.0, 0.0, 8.0),
+ child: bottomJustifiedChild,
+ padding: new EdgeDims(0.0, 8.0, 0.0, 8.0),
Hixie 2015/06/10 17:57:13 Use the EdgeDims constructor for symmetric sides.
hansmuller 2015/06/10 18:06:24 Done. That's much clearer.
decoration: new BoxDecoration(
backgroundColor: backgroundColor,
boxShadow: Shadow[2]

Powered by Google App Engine
This is Rietveld 408576698