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

Unified Diff: sky/sdk/lib/widgets/menu_item.dart

Issue 1235443002: Support for icon theming (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: fix tests 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 side-by-side diff with in-line comments
Download patch
Index: sky/sdk/lib/widgets/menu_item.dart
diff --git a/sky/sdk/lib/widgets/menu_item.dart b/sky/sdk/lib/widgets/menu_item.dart
index 98de178cf1a6faab4fbdcf20db0dc5eca933a154..8044b1741036941d505c99a6e7f1ea6a83bc7ebd 100644
--- a/sky/sdk/lib/widgets/menu_item.dart
+++ b/sky/sdk/lib/widgets/menu_item.dart
@@ -49,15 +49,6 @@ class MenuItem extends ButtonBase {
return result;
}
- String get iconSuffix {
- switch(Theme.of(this).brightness) {
- case ThemeBrightness.dark:
- return "white";
- case ThemeBrightness.light:
- return "black";
- }
- }
-
Widget buildContent() {
List<Widget> flexChildren = new List<Widget>();
if (icon != null) {
@@ -66,7 +57,7 @@ class MenuItem extends ButtonBase {
opacity: selected ? 1.0 : 0.45,
child: new Padding(
padding: const EdgeDims.symmetric(horizontal: 16.0),
- child: new Icon(type: "${icon}_${iconSuffix}", size: 24)
+ child: new Icon(type: icon, size: 24)
)
)
);

Powered by Google App Engine
This is Rietveld 408576698