From 8a0caf8ed4a1dab35e3c4651011c7952fb63aa51 Mon Sep 17 00:00:00 2001 From: Eric Seidel Date: Thu, 4 Jun 2015 15:18:09 -0700 Subject: [PATCH] Start making input work Does not work yet. R=ianh@google.com Review URL: https://codereview.chromium.org/1163973005 --- examples/stocks2/lib/stock_app.dart | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/examples/stocks2/lib/stock_app.dart b/examples/stocks2/lib/stock_app.dart index 23905d6f2c..7e68f94f81 100644 --- a/examples/stocks2/lib/stock_app.dart +++ b/examples/stocks2/lib/stock_app.dart @@ -8,9 +8,9 @@ import 'package:sky/framework/components2/drawer.dart'; // import 'package:sky/framework/components2/floating_action_button.dart'; // import 'package:sky/framework/components2/icon.dart'; import 'package:sky/framework/components2/icon_button.dart'; -// import 'package:sky/framework/components2/input.dart'; import 'package:sky/framework/components2/menu_divider.dart'; import 'package:sky/framework/components2/menu_item.dart'; +import 'package:sky/framework/components2/input.dart'; // import 'package:sky/framework/components2/modal_overlay.dart'; // import 'package:sky/framework/components2/popup_menu.dart'; // import 'package:sky/framework/components2/radio.dart'; @@ -30,9 +30,6 @@ enum StockMode { optimistic, pessimistic } class StocksApp extends App { - // static final Style _searchBarStyle = new Style(''' - // background-color: ${Grey[50]};'''); - // static final Style _titleStyle = new Style(''' // ${typography.white.title};'''); @@ -179,16 +176,16 @@ class StocksApp extends App { // TODO(abarth): Should we factor this into a SearchBar in the framework? UINode buildSearchBar() { - // return new StyleNode( - // new ToolBar( - // left: new IconButton( - // icon: 'navigation/arrow_back_grey600', - // onGestureTap: _handleSearchEnd), - // center: new Input( - // focused: true, - // placeholder: 'Search stocks', - // onChanged: _handleSearchQueryChanged)), - // _searchBarStyle); + return new ToolBar( + left: new IconButton( + icon: 'navigation/arrow_back_grey600', + onGestureTap: _handleSearchEnd), + center: new Input( + focused: true, + placeholder: 'Search stocks', + onChanged: _handleSearchQueryChanged), + backgroundColor: colors.Grey[50] + ); } void addMenuToOverlays(List overlays) {