| OLD | NEW |
| 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 '../painting/text_style.dart'; | 5 import '../painting/text_style.dart'; |
| 6 import 'basic.dart'; | 6 import 'basic.dart'; |
| 7 import 'button_base.dart'; | 7 import 'button_base.dart'; |
| 8 import 'default_text_style.dart'; | 8 import 'default_text_style.dart'; |
| 9 import 'icon.dart'; | 9 import 'icon.dart'; |
| 10 import 'ink_well.dart'; | 10 import 'ink_well.dart'; |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 void syncFields(MenuItem source) { | 36 void syncFields(MenuItem source) { |
| 37 icon = source.icon; | 37 icon = source.icon; |
| 38 children = source.children; | 38 children = source.children; |
| 39 onPressed = source.onPressed; | 39 onPressed = source.onPressed; |
| 40 super.syncFields(source); | 40 super.syncFields(source); |
| 41 } | 41 } |
| 42 | 42 |
| 43 TextStyle get textStyle { | 43 TextStyle get textStyle { |
| 44 TextStyle result = Theme.of(this).text.body2; | 44 TextStyle result = Theme.of(this).text.body2; |
| 45 if (highlight) | 45 if (highlight) |
| 46 result = result.copyWith(color: Theme.of(this).primary[500]); | 46 result = result.copyWith(color: Theme.of(this).primaryColor); |
| 47 return result; | 47 return result; |
| 48 } | 48 } |
| 49 | 49 |
| 50 Widget buildContent() { | 50 Widget buildContent() { |
| 51 return new Listener( | 51 return new Listener( |
| 52 onGestureTap: (_) { | 52 onGestureTap: (_) { |
| 53 if (onPressed != null) | 53 if (onPressed != null) |
| 54 onPressed(); | 54 onPressed(); |
| 55 }, | 55 }, |
| 56 child: new Container( | 56 child: new Container( |
| (...skipping 13 matching lines...) Expand all Loading... |
| 70 child: new Flex(children, direction: FlexDirection.horizontal) | 70 child: new Flex(children, direction: FlexDirection.horizontal) |
| 71 ) | 71 ) |
| 72 ) | 72 ) |
| 73 ) | 73 ) |
| 74 ]) | 74 ]) |
| 75 ) | 75 ) |
| 76 ) | 76 ) |
| 77 ); | 77 ); |
| 78 } | 78 } |
| 79 } | 79 } |
| OLD | NEW |