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

Unified Diff: sky/examples/fn/widgets/icon.dart

Issue 993033003: Move example fn widgets into sky/framework/components (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 9 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/examples/fn/widgets/floating_action_button.dart ('k') | sky/examples/fn/widgets/inksplash.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/examples/fn/widgets/icon.dart
diff --git a/sky/examples/fn/widgets/icon.dart b/sky/examples/fn/widgets/icon.dart
deleted file mode 100644
index 263d3f1711d0fc0f55943df7f37a64630cd86742..0000000000000000000000000000000000000000
--- a/sky/examples/fn/widgets/icon.dart
+++ /dev/null
@@ -1,34 +0,0 @@
-part of widgets;
-
-const String kAssetBase = '/sky/assets/material-design-icons';
-
-class Icon extends Component {
-
- Style style;
- int size;
- String type;
-
- Icon({
- String key,
- this.style,
- this.size,
- this.type: ''
- }) : super(key: key);
-
- Node build() {
- String category = '';
- String subtype = '';
- List<String> parts = type.split('/');
- if (parts.length == 2) {
- category = parts[0];
- subtype = parts[1];
- }
-
- return new Image(
- style: style,
- width: size,
- height: size,
- src: '${kAssetBase}/${category}/2x_web/ic_${subtype}_${size}dp.png'
- );
- }
-}
« no previous file with comments | « sky/examples/fn/widgets/floating_action_button.dart ('k') | sky/examples/fn/widgets/inksplash.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698