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

Unified Diff: sky/sdk/example/demo_launcher/lib/main.dart

Issue 1218293017: Deploy TaskDescription to the rest of our demos (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: 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
« no previous file with comments | « no previous file | sky/sdk/example/mine_digger/lib/main.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/sdk/example/demo_launcher/lib/main.dart
diff --git a/sky/sdk/example/demo_launcher/lib/main.dart b/sky/sdk/example/demo_launcher/lib/main.dart
index 61723b390b1d8b776d55bad9072a09e26e5e5ecd..676465c6c55f0cb43d95eca7c3095e1cefef5743 100644
--- a/sky/sdk/example/demo_launcher/lib/main.dart
+++ b/sky/sdk/example/demo_launcher/lib/main.dart
@@ -4,7 +4,6 @@
import 'dart:sky';
-import 'package:mojom/intents/intents.mojom.dart';
import 'package:sky/mojo/activity.dart' as activity;
import 'package:sky/mojo/asset_bundle.dart';
import 'package:sky/mojo/shell.dart' as shell;
@@ -17,6 +16,7 @@ import 'package:sky/widgets/fixed_height_scrollable.dart';
import 'package:sky/widgets/flat_button.dart';
import 'package:sky/widgets/material.dart';
import 'package:sky/widgets/scaffold.dart';
+import 'package:sky/widgets/task_description.dart';
import 'package:sky/widgets/theme.dart';
import 'package:sky/widgets/tool_bar.dart';
@@ -32,18 +32,17 @@ final AssetBundle _bundle = _initBundle();
void launch(String relativeUrl, String bundle) {
Uri url = Uri.base.resolve(relativeUrl);
- ActivityManagerProxy activityManager = new ActivityManagerProxy.unbound();
- ComponentName component = new ComponentName()
+ activity.ComponentName component = new activity.ComponentName()
..packageName = 'org.domokit.sky.demo'
..className = 'org.domokit.sky.demo.SkyDemoActivity';
- Intent intent = new Intent()
+ activity.Intent intent = new activity.Intent()
..action = 'android.intent.action.VIEW'
..component = component
..flags = activity.MULTIPLE_TASK | activity.NEW_DOCUMENT
..url = url.toString();
if (bundle != null) {
- StringExtra extra = new StringExtra()
+ activity.StringExtra extra = new activity.StringExtra()
..name = 'bundleName'
..value = bundle;
intent.stringExtras = [extra];
@@ -179,11 +178,14 @@ class SkyHome extends App {
brightness: ThemeBrightness.dark,
primarySwatch: colors.Teal
),
- child: new Scaffold(
- toolbar: new ToolBar(center: new Text('Sky Demos')),
- body: new Material(
- type: MaterialType.canvas,
- child: new DemoList()
+ child: new TaskDescription(
+ label: 'Sky Demos',
+ child: new Scaffold(
+ toolbar: new ToolBar(center: new Text('Sky Demos')),
+ body: new Material(
+ type: MaterialType.canvas,
+ child: new DemoList()
+ )
)
)
);
« no previous file with comments | « no previous file | sky/sdk/example/mine_digger/lib/main.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698