Commit 75f10ba6 authored by Viktor Lidholt's avatar Viktor Lidholt

Updates work with latest Flutter changes

parent 48a6cd83
...@@ -11,5 +11,3 @@ dependency_overrides: ...@@ -11,5 +11,3 @@ dependency_overrides:
path: ../../sky/packages/sky path: ../../sky/packages/sky
skysprites: skysprites:
path: ../../skysprites path: ../../skysprites
box2d:
path: ../../../../box2d.dart
...@@ -16,7 +16,6 @@ final AssetBundle _bundle = _initBundle(); ...@@ -16,7 +16,6 @@ final AssetBundle _bundle = _initBundle();
ImageMap _images; ImageMap _images;
SpriteSheet _spriteSheet; SpriteSheet _spriteSheet;
TestBedApp _app;
main() async { main() async {
_images = new ImageMap(_bundle); _images = new ImageMap(_bundle);
...@@ -28,29 +27,21 @@ main() async { ...@@ -28,29 +27,21 @@ main() async {
String json = await _bundle.loadString('assets/sprites.json'); String json = await _bundle.loadString('assets/sprites.json');
_spriteSheet = new SpriteSheet(_images['assets/sprites.png'], json); _spriteSheet = new SpriteSheet(_images['assets/sprites.png'], json);
_app = new TestBedApp(); runApp(new App(
runApp(_app); title: 'Test Physics',
} theme: new ThemeData(
class TestBedApp extends App {
Widget build() {
ThemeData theme = new ThemeData(
brightness: ThemeBrightness.light, brightness: ThemeBrightness.light,
primarySwatch: Colors.purple primarySwatch: Colors.purple
); ),
routes: {
return new Theme( '/': (navigator, route) {
data: theme, return new SpriteWidget(
child: new Title(
title: 'Test Physics',
child: new SpriteWidget(
new TestBed(), new TestBed(),
SpriteBoxTransformMode.letterbox SpriteBoxTransformMode.letterbox
) );
) }
); }
} ));
} }
class TestBed extends NodeWithSize { class TestBed extends NodeWithSize {
......
...@@ -10,5 +10,3 @@ dependencies: ...@@ -10,5 +10,3 @@ dependencies:
dependency_overrides: dependency_overrides:
sky: sky:
path: ../sky/packages/sky path: ../sky/packages/sky
box2d:
path: ../../../box2d.dart
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment